Skip to main content

RevisionCollection.Get(SubDocument) Method

Retrieves all revisions related to the specific document part.

Namespace: DevExpress.XtraRichEdit.API.Native

Assembly: DevExpress.RichEdit.v24.1.Core.dll

NuGet Packages: DevExpress.RichEdit.Core, DevExpress.Win.Navigation

Declaration

IEnumerable<Revision> Get(
    SubDocument subDocument
)

Parameters

Name Type Description
subDocument SubDocument

An object implementing the SubDocument interface that is the target document part (main body, header or footer, text box or comment.

Returns

Type Description
IEnumerable<Revision>

A collection of revisions related to the target SubDocument.

Remarks

The following properties allow you to access a specific document part’s SubDocument:

Document Part Property
Main Body RichEditDocumentServer.Document
Header or Footer Section.BeginUpdateHeader
Section.BeginUpdateFooter
Comment Comment.BeginUpdate
Text Box TextBox.Document

The code sample below shows how to get revisions made in the text box:

foreach (Shape shape in documentProcessor.Document.Shapes)
{
    if (shape.TextBox != null)
    {
        var textBoxRevisions = documentRevisions.Get(shape.TextBox.Document);
    }
}
See Also