Back to Devexpress

AnnotationOptions.TrackChanges Property

officefileapi-devexpress-dot-xtrarichedit-dot-annotationoptions.md

latest5.1 KB
Original Source

AnnotationOptions.TrackChanges Property

Provides access to the Track Changes options.

Namespace : DevExpress.XtraRichEdit

Assembly : DevExpress.RichEdit.v25.2.Core.dll

NuGet Package : DevExpress.RichEdit.Core

Declaration

csharp
public TrackChangesOptions TrackChanges { get; }
vb
Public ReadOnly Property TrackChanges As TrackChangesOptions

Property Value

TypeDescription
TrackChangesOptions

A TrackChangesOptions object containing Track Changes options.

|

Property Paths

You can access this nested property as listed below:

Object TypePath to TrackChanges
RichEditControlOptionsBase

.Annotations .TrackChanges

|

Remarks

Tip

Set the TrackChangesOptions.DisplayForReviewMode property to DisplayForReviewMode.NoMarkup to hide changes on print or export to PDF.

csharp
TrackChangesOptions trackChangesOptions = documentProcessor.Options.Annotations.TrackChanges;

//Change review mode:
trackChangesOptions.DisplayForReviewMode = DisplayForReviewMode.SimpleMarkup;

//Change display options for insertions and format changes:
trackChangesOptions.DisplayFormatting = DisplayFormatting.ColorOnly;
trackChangesOptions.FormattingColor = RevisionColor.ClassicBlue;
trackChangesOptions.DisplayInsertionStyle = DisplayInsertionStyle.Underline;
trackChangesOptions.InsertionColor = RevisionColor.DarkRed;
vb
Dim trackChangesOptions As TrackChangesOptions = documentProcessor.Options.Annotations.TrackChanges

'Change review mode:
trackChangesOptions.DisplayForReviewMode = DisplayForReviewMode.SimpleMarkup

'Change display options for insertions and format changes:
trackChangesOptions.DisplayFormatting = DisplayFormatting.ColorOnly
trackChangesOptions.FormattingColor = RevisionColor.ClassicBlue
trackChangesOptions.DisplayInsertionStyle = DisplayInsertionStyle.Underline
trackChangesOptions.InsertionColor = RevisionColor.DarkRed

The following code snippets (auto-collected from DevExpress Examples) contain references to the TrackChanges property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

word-document-api-use-track-changes/CS/word-processing-document-api-track-changes/Program.cs#L24

csharp
TrackChangesOptions trackChangesOptions = documentProcessor.Options.Annotations.TrackChanges;

winforms-rich-edit-manage-tracked-changes/CS/XtraRichEdit_TrackChanges/Form1.cs#L65

csharp
{
    TrackChangesOptions trackChangesOptions = richEditControl1.Options.Annotations.TrackChanges;

word-document-api-use-track-changes/VB/word-processing-document-api-track-changes/Program.vb#L21

vb
Dim trackChangesOptions As TrackChangesOptions = documentProcessor.Options.Annotations.TrackChanges

winforms-rich-edit-manage-tracked-changes/VB/XtraRichEdit_TrackChanges/Form1.vb#L54

vb
Private Sub SpecifyDisplayOptions()
    Dim trackChangesOptions As TrackChangesOptions = richEditControl1.Options.Annotations.TrackChanges
    'Specify how revisions should be displyed in the document:

See Also

AnnotationOptions Class

AnnotationOptions Members

DevExpress.XtraRichEdit Namespace