mergeDocx
- addBackgroundImage
- addFooter
- addHeader
- addLineNumbering
- addPageBorders
- addProperties
- addSection
- createDocx
- createCharacterStyle
- createListStyle
- createParagraphStyle
- createTableStyle
- docxSettings
- embedFont
- importHeadersAndFooters
- importStyles
- modifyPageLayout
- removeFooters
- removeHeaders
- setBackgroundColor
- setDefaultFont
- setDocumentDefaultStyles
- setEncodeUTF8
- setLanguage
- setMarkAsFinal
- setRTL
- addBibliography
- addBookmark
- addBreak
- addChart
- addCitation
- addComment
- addCrossReference
- addDateAndHour
- addEndnote
- addExternalFile
- addFootnote
- addFormElement
- addHeading
- addImage
- addLink
- addList
- addMathEquation
- addMergeField
- addOLE
- addPageNumber
- addShape
- addSimpleField
- addSource
- addStructuredDocumentTag
- addTable
- addTableContents
- addText
- addTextBox
- addWordML
- embedHTML
- clearBlocks
- deleteTemplateBlock
- getTemplateVariables
- getTemplateVariablesType
- modifyInputFields
- modifyMergeFields
- processTemplate
- removeTemplateVariable
- replaceListVariable
- replacePlaceholderImage
- replaceTableVariable
- replaceVariableByExternalFile
- replaceVariableByHtml
- replaceVariableByText
- replaceVariableByWordFragment
- replaceVariableByWordML
- setTemplateSymbol
- tickCheckbox
mergeDocx
ADVANCED / PREMIUM
BASIC
Merges Word documents.
Description
public void mergeDocx(ArrayList documents, String target) throws Exception
public void mergeDocx(ArrayList documents, String target, Integer mergeType, Boolean enforceSectionPageBreak) throws Exception
public void mergeDocx(ArrayList documents, String target, Integer mergeType, Boolean enforceSectionPageBreak, String numbering) throws Exception
public void mergeDocx(ArrayList documents, String target, Integer mergeType, Boolean enforceSectionPageBreak, String numbering, Integer lineBreaks) throws Exception
public void mergeDocx(ArrayList documents, String target, Integer mergeType, Boolean enforceSectionPageBreak, String numbering, Integer lineBreaks, Boolean preserveStyleDefaults) throws Exception
This method allows the full merging of DOCX documents.
The merging process preserves:
- styles
- images
- charts
- links and cross-references
- lists
- altChunk contents
- footnotes and endnotes
- comments
- OLE objects
- sections with their corresponding headers and footers (optional)
Parameters
documents
Word documents to merge.
target
The destination path of the merged file.
mergeType
"0", preserves the sections of the merged document with their respective headers and footers. "1", merges the contents at the end of the last section of the first document.
enforceSectionPageBreak
Enforces a page section break between documents even if the first section type of the merged document is of the continuous type.
numbering
The destination path of the merged file.
lineBreaks
Inserts the indicated number of line breaks between the contents of the merging files.