PDA

View Full Version : Mail Merge Macro with Query



CaliBlu
02-22-2005, 09:45 AM
I'm using a web app to initiate 3 different templates. Within those templates, a macro runs that does a mail merge and print the letters and closes that document.

I have a query set for each document. It looks in the data source (a column in an Excel spreadsheet) for specific criteria. If it finds that criteria it includes that record in the mail merge.

This seems to work unless it doesn't find any criteria that meets. Instead of just ignoring the merge part it gives an error.

I'd like to have the Word macro not error if it doesn' t find merge criteria.

Ken Puls
02-22-2005, 02:42 PM
Hi CaliBlu,

Welcome to VBAX! It might help our Experts answer your question if you could provide a sample file or any code that you are using. :yes

Just be advised that you need to zip a file to attach it, and be sure to remove any confidential info.

:hi: