I want to create a bulleted/numbered list in a docx word document with Java. I am using the Apache POI 3.10 library. If I understand correctly, the steps would be like this:
Open the document Get the XWPFNumbering object from the document. Get the list of XWPFParagraphs from the document. Step through the list of paragraphs and as you get each one try to get the number ID from it. If this returns null then the paragraph is not in a list. If it does not return null, you can use the BigInteger to retrieve, from the XWPFNumbering object, details of the numbering/bulleting scheme applied to the paragraph.
I referred from this website