Prevent MODI from opening after PrintOut
I am trying to perform a mail merge from word that will result in an individual tiff file for each merge record. I am using Cindy Meister's code to merge to a file and then programmatically save each page as a separate file. Instead of using SaveAs, I have substitued PrintOut and set the active printer to MODI. Everything is working splendidly except that the MODI printer driver insists on opening a file in the MODI viewer after it is "printed". This creates obvious problems when merging a few hundred records at a time in this manner. I have done extensive research on the MODI object to no avail. I have also tried using AppActivate with SendKeys. No matter what I try, I cannot get the MODI viewer to either A) Close after opening printed file, or B) Not open in the first place. Is anyone aware of a solution to my problem or a better approach to achieve my objective?
Thank you in advance for your time and assistance.
|