Free Support Forum -

Word Document Compare Revision Style and Colours


Using the code below I am able to perform a word document compare and get back the revisions.

We would like to be able to change the style/colour of how the different revision’s appear within the compared document

For Example

A deletion will currently appear as Red, with a strike though, we would like to show this as Dark Blue Text, with a light blue highlighted background

An inserting will currently appear as Red, with an underling, we would lie to show this as Dark Green Text, with a light green highlighted background



            // file 1
            var fileStream1 = new MemoryStream(fileContents1);
            var wordDocument1 = new Document(fileStream1);

            // file 2
            var fileStream2 = new MemoryStream(fileContents2);
            var wordDocument2 = new Document(fileStream2);

            // perform the document compare
            wordDocument1.Compare(wordDocument2, "WordComparer", DateTime.Now);

            foreach (Aspose.Words.Revision revision in wordDocument1.Revisions)


Thanks for your inquiry. Please check RevsionsOptions class properties, it will help you to accomplish the task. However, If you face any issue then please share your sample input and expected output document here, we will look into it and will guide you accordingly.


Best Regards,


I can see that I can set the text colour, is it possible to set the background colour?

Based on the RevisionType I can set the following RevisionOptions

RevisionType = Deletion
set DeletedTextColor

   RevisionType = Insertion
                 set InsertedTextColor

   RevisionType = Moving
                 set MovedFromTextColor and MovedToTextColor

What about the other two revision types, FormatChange and StyleDefinitionChange, i can find nothing?

In addion I have created two test docs, the 2nd doc is a copy of docs 1 + it contains text insertions/deletions/changes/moved and format changes
(example format changes are Bold/Italic/Size/Different Font)

when I perform a compare of the two docs, I cant see any highlighting for the format changes, please advise


Thanks for your feedback. Please note RevisedPropertiesColor and RevisedPropertiesEffect properties are used for FormatChange. In reference to background color of revisions. We will appreciate it if you please share a sample expected document here. We will look into it and will guide you accordingly.

Furthermore, I am looking into StyleDefinitionChange revision type and will update you shortly.

Best Regards,


How do I share the documents?

In my example the style changes are picked up, can not obvious as not there is no revision highlighting for this type


Thanks for your feedback. You can attach your input and expected documents to post as ZIP file.

I am afraid I am not clear about it, do you mean Style changes highlighting are working now?

Best Regards,


Basically if there is format/style change it is not obvious as it is not highlighted within the body of the document in a manor like Inserted or Deleted, as these get a colour change etc…

A format/style change has no colour change applied so its not obvious to the end user, we want to be able to set the colour for a format/style


Thanks for sharing the details.

As requested above, please share your sample input and expected output documents here. It will help us to look into your requirement and guide you.

Best Regards,


I will send this on next week

A post was split to a new topic: Change font color of the insertions and deletions revisions