Change font color of the insertions and deletions revisions

Hi,
I am trying to change the font color of the insertions and deletions. I am using below code and not sure what is wrong in this as I am not able to change any colors.

public void Compare(string document1, string document2, string comparisonDocument, ref int added, ref int deleted)
{
added = 0;
deleted = 0;

        // Load both documents in Aspose.Words
        Document doc1 = new Document(document1);
        Document doc2 = new Document(document2);
        Document docComp = new Document(document1);
        DocumentBuilder builder = new DocumentBuilder(docComp);

        doc1.LayoutOptions.RevisionOptions.InsertedTextColor = Aspose.Words.Layout.RevisionColor.BrightGreen;

        doc1.LayoutOptions.RevisionOptions.DeletedTextColor = Aspose.Words.Layout.RevisionColor.DarkYellow;


        doc1.Compare(doc2, "a", DateTime.Now);

        foreach (Revision revision in doc1.Revisions)
        {
            switch (revision.RevisionType)
            {
                case RevisionType.Insertion:
                    added++;                        
                    break;
                case RevisionType.Deletion:
                    deleted++;
                    break;
            }
            Console.WriteLine(revision.RevisionType + ": " + revision.ParentNode);
        }

        Debug.WriteLine("Revisions: " + doc1.Revisions.Count);
        doc1.Save(comparisonDocument);
    }
}

Please help.
Thanks

@Arash18,

To ensure a timely and accurate response, please ZIP and attach the following resources here for testing:

  • Your input Word documents
  • Aspose.Words generated output document showing the undesired behavior
  • Your expected document which shows the correct output. Please create this document by using Microsoft Word application. Please also list the complete steps that you used in MS Word to produce this expected output.

As soon as you get these pieces of information ready, we will start investigation into your issue and provide you code to achieve the same by using Aspose.Words. Thanks for your cooperation.

ASPOSE.zip (115.5 KB)
Hi, Please find the required documents attached in a zip file. In the code deletion color was mentioned as DarkYellow but I need it to be RED and Insertion to be Green as shown in the desired comparison document.

@Arash18,

We have logged your requirement in our issue tracking system. The ID of this issue is WORDSNET-16935. We will further look into the details of this problem and will keep you updated on the status of this issue. We apologize for your inconvenience.