GroupDocs.Metadata for .NET 17.05 Release Notes

Major Features

There are 2 new features in this regular monthly release. The most notable are:

  • Ability to read all revisions in Word format
  • Ability to accept or reject revisions in Word format

All Changes

KeySummaryCategory
METADATANET-1570Ability to read all revisions in Word formatNew Feature
METADATANET-1722Ability to accept or reject revisions in Word formatNew Feature

Public API and Backward Incompatible Changes

Ability to read all revisions in Word format

This feature allows to read all track changes(revisions) in Word document.

Public API changes

Added RevisionType enum into namespace GroupDocs.Metadata.Formats.Document
Added Revision class into namespace GroupDocs.Metadata.Formats.Document
Added RevisionCollection class into namespace GroupDocs.Metadata.Formats.Document

Given below example demonstrates how to read track changes (revisions) in Word document

// path to the MS Word file
string path = @"c:\download files\CV.docx";

// initialize DocFormat
DocFormat docFormat = new DocFormat(path);

// get revisions
RevisionCollection revisionCollection = docFormat.Revisions;

// get revisions count
Console.WriteLine("Revisions: {0}", revisionCollection.Count);

foreach (Revision revision in revisionCollection)
{
  // display revision type
  Console.WriteLine("Revision -  type: {0}, ", revision.RevisionType);

  // display revision author
  Console.Write("author: {0}, ", revision.Author);

  // display revision date
  Console.Write("date: {0}", revision.DateTime);
}

Ability to accept or reject revisions in Word format

This feature allows to accept or reject track changes (revisions) in Word document.

Public API changes

Added RevisionType enum into namespace GroupDocs.Metadata.Formats.Document
Added Revision class into namespace GroupDocs.Metadata.Formats.Document
Added RevisionCollection class into namespace GroupDocs.Metadata.Formats.Document

This example demonstrates how to accept all changes in Word document.

// path to the MS Word file
string path = @"c:\download files\CV.docx";

// initialize DocFormat
DocFormat docFormat = new DocFormat(path);

// get revisions
RevisionCollection revisionCollection = docFormat.Revisions;

// accept all revisions
revisionCollection.AcceptAll();

// and commit changes
docFormat.Save();

This example demonstrates how to reject all changes in Word document.

// path to the MS Word file
string path = @"c:\download files\CV.docx";

// initialize DocFormat
DocFormat docFormat = new DocFormat(path);

// get revisions
RevisionCollection revisionCollection = docFormat.Revisions;

// reject all revisions
revisionCollection.RejectAll();

// and commit changes
docFormat.Save();