Word export
The Word export produces a .docx document from a List & Label report project using the OpenXML format. It is provided by the combit.ListLabel32.CrossPlatform.Export.OpenXml package and selected with LlExportTarget.Docx.
Unlike the pixel-oriented Excel export, the Word export aims for a good compromise between visual fidelity and editability:
- Text objects (simple texts and formatted RTF texts) keep editable Word text. In the
Editablelayout mode they become real Word paragraphs and runs in the natural document flow. In theBalancedandFixedmodes they become positionally fixed text boxes anchored at their original location, so texts used as labels keep their place on the page. The text inside the box stays fully editable. - Table objects become real Word tables with a column grid inferred from the report layout, including merged cells, repeating header rows, cell borders, fillings and alignments.
- Repeated content at the top or bottom of every page is moved into real Word header and footer parts; page numbers become Word
PAGEfields. - Page size, orientation and margins are mapped to Word section properties. Pages with identical settings share one section; section breaks are only emitted when the page size changes.
- Pictures are embedded as images. In the
Editablelayout mode they are placed inline in the flow; in theBalancedandFixedmodes free-standing pictures become positionally fixed picture drawings anchored at their original location, so pictures placed side by side keep their arrangement instead of stacking vertically. Barcodes, checkboxes, charts, gauges and ellipses are rendered as images because they have no editable Word equivalent. - Tables are not placed in absolutely positioned text boxes or drawings; they always become real, editable Word tables.
Note
The OpenXML package must be installed for DOCX export to be available at runtime. See Installing export packages.
Supported export options
All options are set on ExportConfiguration.ExportOptions using the LlExportOption keys listed below. Values are always strings.
DocxLayoutMode
Controls the trade-off between visual fidelity and editability.
| Value | Meaning |
|---|---|
"Editable" |
Maximizes the use of native Word flow. Texts become ordinary flow paragraphs, manual line wraps of the reference rendering are released so Word wraps text naturally, no explicit page breaks are emitted, tables that continue across pages are joined (repeated header lines are dropped) and no anchored fallback objects are created. Layout deviations are accepted. |
"Balanced" |
Default. Native Word structures wherever they are reliable. Free-standing texts and pictures become positionally fixed text boxes resp. picture drawings at their original location, so labels and side-by-side pictures keep their place on the page. The original pagination is preserved through explicit page breaks. |
"Fixed" |
Like "Balanced", but table row heights become exact instead of grow-able, freezing the table layout as far as possible while still producing real, editable Word tables. |
DocxFontScalingPercentage
Scales all fonts by the given percentage.
- Value: a percentage (for example
"95"for 0.95×). - Default:
"100"(Word reproduces the reference rendering closely, so no scaling is applied by default).
Resolution
Sets the general PPI for exported images, shapes, etc.. Textheavy or very detailed Objects have a higher PPI.
- Value: a positive integer PPI value up to
"2400", for example"300". A higher value is reduced to"2400"; any other value is ignored and the default applies. - Default:
"300".
DocxTitle, DocxSubject, DocxAuthor and DocxKeywords
Set the corresponding core document properties of the generated file.
Editability-oriented behavior
The exporter prefers the author's intent over a pixel-exact reproduction:
- Text is exported as paragraphs and runs with font family, size, color, bold/italic/underline/strikeout and alignment. Mixed formatting (e.g. from formatted text objects) is split into multiple runs. Line breaks inside an object become soft line breaks (
Editablemode releases them entirely). In theEditablemode the paragraphs are placed directly in the document flow; in theBalancedandFixedmodes they are wrapped in a positionally fixed text box anchored at the object's original position, because reports commonly use free-standing texts as labels spread across the page. The text inside the box remains editable. - Tables use a fixed layout grid derived from the field bounds of all table lines. Fields spanning multiple inferred columns become merged cells, gaps are closed with empty filler cells and header lines are marked to repeat when Word reflows the table across pages. Numeric and date values stay editable text exactly as rendered — Word has no cell value types. Decimal alignment is approximated with left/right alignment.
- Multi-column report containers become side-by-side columns that share a top edge. In the
BalancedandFixedmodes each column stays a separate table, kept next to the others by a borderless wrapper table that preserves their geometry. In theEditablemode the columns of one container are merged into a single table placed in a continuous multi-column (newspaper) section, so the content flows from the bottom of one column into the top of the next — and across page breaks — while staying editable as one table. This needs a shared column grid; if a follow-up table changes the column layout, the wrapper table is kept instead. Containers that fill horizontally always stay a single table whose column junctions follow the configured field frames. - Headers and footers are only created when content repeats with identical geometry on every page inside the top or bottom page band. Text that differs between pages exactly by the one-based page number is exported with a Word
PAGEfield, so the numbering stays correct while editing. - Page margins are derived from the bounds of the outermost content, so the flow content starts at the original position without anchoring every object.
Fallback behavior
For content that has no reliable flow equivalent the exporter falls back in this order:
- Native approximation — e.g. horizontal lines become paragraph borders, rectangles wrapping a text object become paragraph borders/shading of that text, standalone rectangles become empty bordered/shaded paragraphs of matching height.
- Anchored drawing — free-standing texts become positionally fixed text boxes and free-standing pictures keep their original position through an anchored picture drawing (
Balanced/Fixedmodes only). A picture the report paints behind a report container or text object is anchored behind the document text in every layout mode, so the table or text on top of it stays readable and editable. Anchoring is localized per object: it does not turn the page into a screenshot. - Rendered image — barcodes, charts, gauges, checkboxes, data graphics and ellipses are rendered as pictures, because an editable reconstruction is not realistic.
Restrictions
The Word export cannot reproduce every aspect of the rendered report. The following limitations are inherent to the format or the current exporter implementation:
- Rotated text is exported unrotated.
- Vertical and diagonal line objects are not exported.
- Gradient fillings are approximated with their primary color; background patterns are not preserved.
- In the
Editablelayout mode, content placed side by side outside of tables is exported in reading order (top to bottom, left to right) and stacks vertically. TheBalancedandFixedmodes keep free-standing texts and pictures at their original position, so side-by-side arrangements are preserved. - Tables that continue across pages are exported as one table per page (except in the
Editablelayout mode, where matching tables are joined). In theEditablemode a picture placed behind the table interrupts the join on the page it appears on, because the anchored background picture is carried by a paragraph at that page's start: a continued table is split there, and a multi-column container is closed and reopened as a second newspaper section. - In the
Editablelayout mode the multi-column (newspaper) flow of a report container is laid out by Word, so the exact split of records between columns and pages may differ from the reference rendering. - Bullets and numbering are reproduced for simple single-level lists from formatted text; complex multi-level list formatting is simplified.
- Images embedded in RTF text are exported when stored as PNG or JPEG; metafile (EMF/WMF) and raw device-bitmap formats are skipped.
- Right-to-left text is not supported.
- Decimal alignment is approximated with left/right alignment.
- Headers and footers are only detected for documents with at least two pages; per-page differing content (apart from the page number) stays in the body.
- Line and paragraph spacing inside text objects are approximated; exact line positions may differ slightly from the reference rendering.
- Copy printing and expandable regions are not supported.
- The table column grid is inferred from the field bounds, so all sections (header line, data line, …) and line definitions share one grid. Cell borders that are not justified across these sections can shift the inferred grid; justify the borders of cells that recur in multiple sections, and let the columns of a line add up to the container width, to avoid a distorted table in Word.
- The column compress (shrink-to-fit) option is not applied; Word table cells do not shrink their text to fit.
- Tab characters in text are preserved, but report tab-stop positions are not mapped to Word tab stops.
- Control characters that Word cannot display are not filtered out; remove them in the report if they occur.
- A report container's own background color is not exported (the fillings of its table cells are).
- A frame around a whole table object and the background color of an individual table are not exported (cell-level borders and fillings are).
- A table of contents or index is exported as a plain table without a live Word field, bookmarks or links.
- Hyperlinks are exported for pictures, but not for text; text stays unlinked.