Problem with function Cleanup() of Aspose Word .NET

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

@dunghnguyen

We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSNET-18579. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

The issues you have found earlier (filed as WORDSNET-18579) have been fixed in this Aspose.Words for .NET 19.6 update and this Aspose.Words for Java 19.6 update.