Hi,
I'm trying to replace the document.xml for a given document. I have the following code based on the ImportForeignPart sample. It generates the resulting document however there is a problem when trying to open the document. Further investigation revealed that only the document.xml file exists under /word directory in the output document (all other files and directories are missing). Would appreciate your help on this.
WordprocessingMLPackage template = WordprocessingMLPackage.load(new File(this.getServletContext().getRealPath("/") + "/template.docx"));
InputStream ...