Hi,
How to insert field( like : pageNum , num of pages ) in paragraph and set style for field like incresing font size and color ?
Hi,
Hi Anbu,
Hi awais ,
Hi Anbu,
Document doc = new Document(getMyDir() + “in.docx”);NodeCollection fields = doc.getChildNodes(NodeType.FIELD_START, true);
FieldStart fieldStart = (FieldStart)fields.get(0);for (Node node = fieldStart; node != null && node.getNodeType() != NodeType.FIELD_END; node = node.nextPreOrder(node.getDocument()))
{
if (node.getNodeType() == NodeType.RUN)
((Run)node).getFont().setSize(24);
}doc.save(getMyDir() + “out.docx”);