invalid merge field - trapping error

J

johan

when executing a mail-merge (vba) there's an error message "invalid
merge field" when the merge field is not in the database... the
error-handling routine in my vba-code seems not able to trap this
error... any advice ?
 
P

Peter Jamieson

You could consider getting your VBA to loop through each { MERGEFIELD }
field in the document, extract the merge field name, and ensure it exists in
the Document.MailMerge.DataSource.Datafields collection.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top