Class MergeDocx


public class MergeDocx extends AbstractSample
This sample demonstrates how the MergeDocx utility can be used to merge docx documents. The MergeDocx utility is a paid extension to docx4j. Purchases of this extension support the docx4j project.
See Also:
  • merging-word-documents blog post for more info, or
  • www.plutext.com or email sales@plutext.com if you want to buy it. To run the utility, you simply pass it a list of the docx you want to merge; it returns a new pkg containing the merged documents. This example looks a little more complex, since it has to use reflection, so that docx4j can still be built by users who don't have the MergeDocx code.
  • Field Details

    • BASE_DIR

      static final String BASE_DIR
    • sourceDocxNames

      static final String[] sourceDocxNames
    • save

      static boolean save
    • outputfilepath

      static String outputfilepath
  • Constructor Details

    • MergeDocx

      public MergeDocx()
  • Method Details