Hi,
Is it possible to remove a specific color highlight from a docx file? For example, change gray highlight to no color if exists in docx.
Thanks for any help.
It is currently Sat Feb 22, 2025 7:26 pm
File templateZip = new File("resources/doctest.docx")
WordprocessingMLPackage template = WordprocessingMLPackage.load(templateZip)
def map = ["pagebreak": "<w:r><w:br w:type=\"page\"/></w:r>"]
template.mainDocumentPart.variableReplace(map)
if (template.isGenerateToc()) {
Toc.setTocHeadingText("Inhaltsverzeichnis");
TocGenerator tocGenerator = new TocGenerator(wordPackage);
tocGenerator.generateToc(2, " TOC \\o \"1-3\" \\h \\z \\u ", true);
}
Total posts 10142 • Total topics 2852 • Total members 2083