How to append RTF content to a Word document ?

Hi I'm creating a word document dynamically i have a set of RTF content which i need to append to the word document. How can i do this ?

1 Reply

RH Ramanan  Hariharasubramanian Syncfusion Team December 6, 2017 12:41 PM UTC

Hi Marimuthu,

Thank you for contacting Syncfusion support.

At present, DocIO does not have direct API to append the RTF content into an existing Word document.


You can use the below solution to append RTF content to an existing Word document.

1. Open the RTF content as new WordDocument instance.
 
2. Import this WordDocument instance, to the destination Word document using ImportContent() method.

We have prepared sample for the same. Please find the sample from below location.

Sample link:
http://www.syncfusion.com/downloads/support/forum/134902/ze/Sample-629532520

To know more about ImportContent method kindly refer the below UG documentation link.
https://help.syncfusion.com/cr/file-formats/Syncfusion.DocIO.DLS.WordDocument.html#Syncfusion_DocIO_DLS_WordDocument_ImportContent_Syncfusion_DocIO_DLS_IWordDocument_

Kindly let us know if the sample fulfills your requirement.

Regards,
Ramanan H


Loader.
Up arrow icon