Hi,
I have a issue with function Cleanup() of Aspose Word .NET. The description of function say: " Cleans unused styles and lists from the document.". But when I use it then save the document, the unused list back to 1.
Sample code:
Document doc = new Document(inFile);
int numOfListBefore = doc.Lists.Count; // The result is 1
doc.Cleanup();
int numOfListAfterClean = doc.Lists.Count; // The result is 0
doc.Save(outFile, SaveFormat.Doc);
int numOfListAfterSave = doc.Lists.Count; // The result is 1
You can change they way to check by re-open the outFile again, the result is the same, number of list back to 1 after saving.
I’ve tested with Aspose Word 19.5 and the issue still happen. Here is the sample file: sample.zip (571.6 KB)
Please check and help me with this issue.
Thanks,
Dung H. Nguyen