Determining if an Open XML WordprocessingML Document contains Tracked Changes
Processing tracked changes (sometimes known as tracked revisions) is something important that you should full understand when writing Open XML applications. If you first accept all tracked revisions, your job of processing or transforming the WordprocessingML is made significantly easier.
This blog is inactive.
New blog: EricWhite.com/blog
Blog TOCI’ve written an MSDN article, Accepting Revisions in Open XML Word-Processing Documents, which details the semantics of the elements and attributes of WordprocessingML that hold tracked changes information. Further, I’ve written code, in CodePlex.com/PowerTools, that implements tracked changes as detailed in the above article. Go to the Downloads tab, and download RevisionAccepter.zip.
However, there are other scenarios where you want to process documents that you are guaranteed that have no tracked changes, and due to certain business requirements you do not want to automatically accept tracked changes. You might have a SharePoint document library that contains no documents with tracked changes. Before users add the document to that document library, you want them to consciously and intentionally address and accept all tracked revisions. Accepting revisions as part of the process of checking the document into the document library would circumvent the people portion of this process, where you want each person to manually examine their documents and resolve any issues.
The MSDN article, Identifying Open XML Word-Processing Documents with Tracked Revisions, explains in detail how to determine whether a document contains tracked revisions, with samples in both Visual Basic and C#.