Skip to main content
All docs
V25.1
  • PdfMarkupAnnotationComment Class

    Represents a comment added to an annotation.

    Namespace: DevExpress.Pdf

    Assembly: DevExpress.Pdf.v25.1.Core.dll

    NuGet Package: DevExpress.Pdf.Core

    Declaration

    public class PdfMarkupAnnotationComment

    Remarks

    Create a Comment

    The PdfMarkupAnnotationData.AddReply method adds a comment to the annotation.

    Call the PdfMarkupAnnotationComment.AddReply method to create a nested comment.

    Use the PdfMarkupAnnotationComment members to change the reply’s author, subject and text.

    The code sample below creates two nested comments and adds a review to the second comment (the document is opened in DevExpress WinForms PDF Viewer):

    annotations-comment

    private static void AddAnnotationComments(PdfMarkupAnnotationData annotation)
    {
        PdfMarkupAnnotationComment comment =
        annotation.AddReply("Reviewer", "Done");
        comment.Subject = "Proofread";
    
        PdfMarkupAnnotationComment nestedComment =
        comment.AddReply(annotation.Author, "Thanks");
        nestedComment.Subject = "Reviewed";
    }
    

    Access Comments

    The PdfMarkupAnnotationData.Replies and PdfMarkupAnnotationComment.Replies properties obtain all comments added to an annotation or comment.

    CODE

    Remove Comments

    Pass the comment that should be removed as the PdfMarkupAnnotationData.RemoveReply (the PdfMarkupAnnotationComment.RemoveReply for nested comments) method parameter to remove it.

    CODE

    Inheritance

    Object
    PdfMarkupAnnotationComment
    See Also