Questions tagged [docx4j]

Docx4j is an open source (ASLv2) Java library for manipulating Microsoft OpenXML files (Word docx, Powerpoint pptx, and Excel xlsx) via JAXB

Docx4j is a Java library for manipulating Microsoft OpenXML files (Word docx, Powerpoint pptx, and Excel xlsx). It uses JAXB to create the in-memory representation.

It is similar to Microsoft's OpenXML SDK, but for Java. docx4j uses JAXB to create the in-memory object representation.

It is available under the Apache License (v2).

docx4j was created by Plutext Pty Ltd in 2008 - using OpenXML4J for the OPC piece. Plutext still drives the project, but since then docx4j has benefited from contributions from many individuals. The contributors are listed in docx4j's pom.xml.

The docx4j online demo is available here.

911 questions
-1
votes
1 answer

Replace placeholder in text box docx4j

I am using docx4j. I have word document where i drew a text box. In that text box, i have the word "dummyPlaceHolderInTextBox". I would like to replace this placeholder word with "testString" as shown in the method i called below. This is not…
Ninja Dude
  • 1,332
  • 4
  • 27
  • 54
-1
votes
4 answers

Android Docx4J Gradle: Duplicate class org.slf4j despite excluding it

I am trying to use the Docx4j library in order to read in the contents of MS Word files selected by the user (I am trying to install it through this example: https://github.com/plutext/Docx4j4Android4). However, I receive the following error when I…
Adam Lee
  • 436
  • 1
  • 14
  • 49
-1
votes
1 answer

Is it possible to create an excel spreadsheet through Android Studio?

I am looking to make an app that allows users to enter information into several fields, and when they submit, the data is formatted into an excel file.
nickyc918
  • 3
  • 2
-1
votes
1 answer

update word Customxml part using of OpenXml API, but can't update "document.xml" in Main Document

we update custom xml part using C# code. we are successfully update document in widows. but can we open this document in Linux environment, it could not be changed value. how can we achieve change of custom xml part in windows as well as…
-1
votes
2 answers

docx4j: Read data between two bookmarks of docx file using Java

I am doing a task in which I need to read data between two bookmarks of docx file using Java. I got all the name of bookmarks by using docx4j api using below code- WordprocessingMLPackage wordMLPackage = WordprocessingMLPackage.load(new…
Mostch Romi
  • 531
  • 1
  • 6
  • 19
-1
votes
1 answer

Plutext's PDF Converter restrictions

I have planned to use up docx4j library for my JAVA application for docx to PDF conversion. But, since the version v3.3.0 of DOCX4j the PDF output is by default via Plutext's commercial PDF Converter, will i be restricted to the number of documents…
ladyDon303
  • 73
  • 7
-1
votes
1 answer

Docx4j convert docx to pdf and text box is not appear

document.xml document.docx here is the link for my document. I'm trying to convert the DOCX to PDF. I'm able to covert it, but i realize the text box in the DOCX is gone after converted to PDF. How can I solve this problem? Below is the code that…
codingDummy
  • 122
  • 2
  • 14
-1
votes
1 answer

Docx4J convert Chinese to pdf

I'm having the following code to convert docx file to pdf file, my docx content having text box and Chinese characters. String myFilePath = "testing.docx"; File docxFile = new File("testing.docx"); WordprocessingMLPackage wordprocessingMLPackage =…
codingDummy
  • 122
  • 2
  • 14
-1
votes
2 answers

Replace Content Controls with text

I need to replace content controls with text in word document using docx4j I refer this link ,I'm not able to understand how to get .xml file from .docx file Does anyone know where I can find code examples of this?
Padma
  • 11
  • 4
-1
votes
1 answer

Variables did not replaced

I wrote some code to replace variables in docx tamplate file header. List sectionWrappers = this.wordMLPackage.getDocumentModel().getSections(); for (SectionWrapper sw : sectionWrappers) { HeaderFooterPolicy hfp =…
Zaosz
  • 137
  • 1
  • 2
  • 11
-1
votes
1 answer

Docx to Pdf with replaced characters

I have a docx file with Chinese characters and other Asian languages. I am able to convert the docx file into a PDF file perfectly on my laptop with the Chinese characters embedded properly into the PDF, but when the same code is run as runable jar…
-1
votes
1 answer

Generate Graphs Using xlsx4j?

Please can i have a good answer for my question : I need to generate a docx file with editable graphs I wanna know if i can use xlsx4j to generate charts then, i'll put them in docx using (OLE objects) ? Thanks for advance.
-1
votes
1 answer

insert annotation to a word document by using POI or DOCX4J

I'd like to insert some annotations into work documents by using Java or Python. I tried POI, DOCX4J and python-docx. But unfortunately until now I didn't figure out how to use them to generate annotation in a word document. Any advice would be…
S.SMITH
  • 11
-1
votes
1 answer

Hide Docx4j message in JavaFX

I have these message on all converted files to PDF via Docx4j. TO HIDE THESE MESSAGES, TURN OFF log4j debug level logging fororg.docx4j.convert.out.pdf .viaXSLFO Is it possible to hide it? I found some solution here on Stack but It didn't help me…
MiOnIs
  • 125
  • 12
-1
votes
1 answer

how to get the TOC of word document use POI or use docx4j?

i have a trouble this days, i cant get the TOC of word use poi,and i try to use docx4j to read the word document,but i cant find a function to get it,some one knows how to get the toc of word document ?
Eric.Cao
  • 1
  • 1
1 2 3
60
61