MergeField Question

Hi Folks,

I'm using Aspose.Words to populate merge fields in a word template. Everything works as expected, except that I need to add an image on each page of the document and the image is different depending on the type of data in the merge fields. So the code goes something like :

documentBuilder.MoveToMergeField("SomeMergeField");
documentBuilder.InsertHtml("Some Text");
documentBuilder.InsertNode(shapeImg);

This works!, however, only when the text "Some Text" does not exceed beyond one page. When the text exceeds one page the image is still inserted but only in the first page of the section, subsequent pages do not have the image. Keep in mind that I just can't insert the same image for the entire document because each section may have a different image.

My question is : How can I insert the image node in all the pages of the section ?

Thanks!
Regards,
Julio.

Hi Julio,


Thanks for your inquiry. You can easily insert an image into a MERGEFIELD during executing Mail Merge process. Please follow the link to learn how to achieve this:
http://www.aspose.com/docs/display/wordsnet/How+to++Insert+Images+from+a+Database

Please let me know if I can be of any further assistance.

Best Regards,