We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

changing color of text in a word file


How can I add, color to the text, which I replaced here ?

http://www.syncfusion.com/downloads/support/forum/123556/ze/Sample-1573347365.zip

1 Reply

SR Suganya Rathinam Syncfusion Team April 1, 2016 06:31 AM UTC

Hi Customer,

The Find API of DocIO helps to find the text in the Word document and using this API you can get the replaced text as a TextSelection. You can get the selected text as a single text range using the GetAsOneRange API of TextSelection class and change the font properties of the text. We have modified the given sample to change the color of the replaced text and attached the same. Please find the sample from the following link and let us know if it helps.

Sample Link:
http://www.syncfusion.com/downloads/support/forum/123574/ze/Sample-365770238.zip

Please find the following UG documentation link on Find and Replace functionality of DocIO for your reference.
http://help.syncfusion.com/file-formats/docio/working-with-find-and-replace

Regards,
Suganya


Loader.
Live Chat Icon For mobile
Up arrow icon