Click or drag to resize
RevisionsView Enumeration
Allows to specify whether to work with the original or revised version of a document.

Namespace: Aspose.Words
Assembly: Aspose.Words (in Aspose.Words.dll) Version: 20.1
Syntax
public enum RevisionsView
Members
  Member nameValueDescription
Original0 Specifies original version of a document.
Final1 Specifies revised version of a document.
Examples
Shows how to get revised version of list label and list level formatting in a document.
Document doc = new Document(MyDir + "GetRevisedVersionOfDocument.docx");
doc.UpdateListLabels();

// Switch to the revised version of the document
doc.RevisionsView = RevisionsView.Final;

foreach (Revision revision in doc.Revisions)
{
    if (revision.ParentNode.NodeType == NodeType.Paragraph)
    {
        Paragraph paragraph = (Paragraph)revision.ParentNode;

        if (paragraph.IsListItem)
        {
            // Print revised version of LabelString and ListLevel
            Console.WriteLine(paragraph.ListLabel.LabelString);
            Console.WriteLine(paragraph.ListFormat.ListLevel);
        }
    }
}
See Also