Hi guys. When I am trying to compare two word documents as described below, I am getting revisions (documents are not the same) after comparison, even second document is just a copy of first one.
Please advice what I am doing incorrectly in this case?
Aspose.Words.Document docA = new(@"C:\temp\Doc.docx");
Aspose.Words.Document docB = new(@"C:\temp\DocCopy.docx");
// There should be no revisions before comparison.
docA.AcceptAllRevisions();
docB.AcceptAllRevisions();
docA.Compare(docB, "m", DateTime.Now);
docA.Save(@"C:\temp\Doc_Aspose_word_report.pdf");
docA.Revisions // here I am getting 8 revision objects
Some of the revisions:
Aspose.Words.Revision
{
Author = "m",
DateTime = <2023-01-05 12:28:53.3391943>,
Group =
Aspose.Words.RevisionGroup
{
Author = "m",
RevisionType = RevisionType.Insertion {value: 0},
Text = ""
},
ParentNode = {empty},
ParentStyle = "[Member 'ParentStyle' threw an exception: 'Can not access ParentStyle for a node revision. Use ParentNode instead.']",
RevisionType = RevisionType.Insertion {value: 0}
},
Aspose.Words.Revision
{
Author = "m",
DateTime = <2023-01-05 12:28:53.3391943>,
Group =
Aspose.Words.RevisionGroup
{
Author = "m",
RevisionType = RevisionType.Deletion {value: 1},
Text = ""
},
ParentNode = {empty},
ParentStyle = "[Member 'ParentStyle' threw an exception: 'Can not access ParentStyle for a node revision. Use ParentNode instead.']",
RevisionType = RevisionType.Deletion {value: 1}
},
Aspose.Words.Revision
{
Author = "m",
DateTime = <2023-01-05 12:28:53.3391943>,
Group =
Aspose.Words.RevisionGroup
{
Author = "m",
RevisionType = RevisionType.Insertion {value: 0},
Text = ""
},
ParentNode = {empty},
ParentStyle = "[Member 'ParentStyle' threw an exception: 'Can not access ParentStyle for a node revision. Use ParentNode instead.']",
RevisionType = RevisionType.Insertion {value: 0}
},