PPTX PPT ODP PDF ODP
Aspose.Slides  for Java
ODP

Remove Comments and Comment Authors from ODP in Java

Use Aspose.Slides for Java to remove comments and comment authors from presentation files.

Remove Comments from ODP via Java

Aspose.Slides for Java lets you remove comments and comment authors from ODP presentations. Load a file with the Presentation class, iterate through ICommentAuthor objects from getCommentAuthors, clear their comments, and save the updated presentation.

Delete Annotations from ODP - Java

Presentation presentation = new Presentation("presentation.odp");
try {
    for (ICommentAuthor commentAuthor : presentation.getCommentAuthors())
    {
        commentAuthor.getComments().clear();
    }

    presentation.getCommentAuthors().clear();

    presentation.save("cleaned-presentation.odp", SaveFormat.Odp);
} finally {
    presentation.dispose();
}

How to Remove Comments from ODP via Java

  1. Install Aspose.Slides for Java. See Installation .

  2. Load the ODP file with the Presentation class.

  3. Iterate through the ICommentAuthor objects from getCommentAuthors.

  4. Clear each author’s comments with getComments().clear().

  5. Clear the comment author collection and save the updated ODP file.

Other Supported Annotation Formats

You can also remove comments from other presentation formats with Java.