Free Support Forum - aspose.com

Object Reference not Set error in MailMerge.Execute

Hello,

I’m comparing our deployment of Words 6.5.0.0 to 9.0.0.0 and found that if one of our template designers used the following syntax in a merge field, the merge operation results in an “Object Reference not Set” error:

{ MERGEFIELD QUANTITY * # ##,###,### }

The problem here is that the template designer included the * parameter to the left of the picture switch.

I can tell the user to correct the template, but it will introduce a breaking change into my code. Somehow it appears that 6.5.0.0 simply ignored the * in the presence of a picture switch. Is it possible to re-introduce that behavior? It would be a “nice to have” but not essential.

~~ Michael

Hi Michael,

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

Thank you for reporting this problem to us. I managed to reproduce it on my side. Your request has been linked to the appropriate issue. You will be notified as soon as it is resolved.

But anyways, I think that it would be better if you change your template. Even MS Word does not like fields like you provided in your previous post. If you try to update fields in MS Word and there is such field, MS Word shows the following error:

Error! Picture switch must be first formatting switch.

Best regards.

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


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