We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose.Word MailMerge Set Font Color from Source Doc Using Builder

I am doing a mail merge and populating a new document with data using Builder. Is it possible to get the font color of the mergefield in the source document and use that to set the font color for the field using Builder?

@jlserpe

Thanks for your inquriy. Please check following code snippet to get font color of MailMerge field. Hopefully it will help you to accomplish the task.

DocumentBuilder builder = new DocumentBuilder(doc);
builder.MoveToMergeField(mailmergefield);
System.Drawing.Color color = builder.Font.Color;
Console.WriteLine( "color:" + color);