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

Free Support Forum - aspose.com

MailMerge problem with formatting switches


During mailmerge, if the value of a mergefield with a date formatting switch is not a date, a FormatException is thrown. In this case, Microsoft Word simply ignores the field. Could Aspose.Words have the same behavior?

Here is the code to reproduce this :

Document doc = new Document(“KO.doc”);
MailMerge mailMerge = doc.MailMerge;
string[] fieldNames = {“DATE”};
string[] values = {“aa”};
mailMerge.Execute(fieldNames, values);



<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your request. We will consider your suggestion and provide you more information.

Best regards.


The latest versions of Aspose.Words do not throw exception in this situation, but they do not ignore such merge fields either. Instead, they do perform mail merge but ignore the formatting switch that is not acceptable to the incoming data. This is the most logical way I believe.


The issues you have found earlier (filed as 9419) have been fixed in this update.

This message was posted using Notification2Forum from Downloads module by aspose.notifier.