RevisionsView enumeration

RevisionsView enumeration

Allows to specify whether to work with the original or revised version of a document.

Members

NameDescription
OriginalSpecifies original version of a document.
FinalSpecifies revised version of a document.

Examples

Shows how to switch between the revised and the original view of a document.

let doc = new aw.Document(base.myDir + "Revisions at list levels.docx");
doc.updateListLabels();

let paragraphs = doc.firstSection.body.paragraphs;
expect(paragraphs.at(0).listLabel.labelString).toEqual("1.");
expect(paragraphs.at(1).listLabel.labelString).toEqual("a.");
expect(paragraphs.at(2).listLabel.labelString).toEqual('');

// View the document object as if all the revisions are accepted. Currently supports list labels.
doc.revisionsView = aw.RevisionsView.Final;

expect(paragraphs.at(0).listLabel.labelString).toEqual('');
expect(paragraphs.at(1).listLabel.labelString).toEqual("1.");
expect(paragraphs.at(2).listLabel.labelString).toEqual("a.");

See Also