Programmatically address the Save Dialog Box

Q

qbutler

I have a publisher document that connects to a database and completes a mail
merge from an access DB table. The mailmerge completes into a new
publication. However I then have two instances of publisher open which is
fine. However when I close the merged document which contains the names from
the database I am prompted whether I want to save or not, that is ok. But
when I close the instance that has my template and the code I do not want to
be prompted with the save dialog box. Is there a way to programmatically
answer no to this question. I did try using:

Thisdocument.saved = true

to try and trick the application that it has already been saved and not to
prompt but it is a read only value and can not be modified.

Any insight on how I can accomplish this is greatly appreciated.
 
E

Ed Bennett

qbutler said:
I have a publisher document that connects to a database and completes a mail
merge from an access DB table. The mailmerge completes into a new
publication. However I then have two instances of publisher open which is
fine. However when I close the merged document which contains the names from
the database I am prompted whether I want to save or not, that is ok. But
when I close the instance that has my template and the code I do not want to
be prompted with the save dialog box.

Is the template being opened from code? If so, one of the optional
arguments for the .Open method is whether to prompt to save changes,
silently save changes, or silently discard changes.
 
Q

qbutler

Is the template being opened from code? If so, one of the optional
arguments for the .Open method is whether to prompt to save changes,
silently save changes, or silently discard changes.
Thanks Ed,

Initially I was not opening from code because I was still trying to make
sure I had my logic together from just the Publisher side of the house.
However I have made the transition over into Access, added my references,
created a button on a form. The button opens my publisher template and
successfully completes the mailmerge. It then closes my template with out
user interaction leaving open only the merged document. Which is what I was
looking for.

I believe you have resolved this issue for me.

Thanks bunches!
 
E

Ed Bennett

qbutler said:
However I have made the transition over into Access, added my references,
created a button on a form. The button opens my publisher template and
successfully completes the mailmerge. It then closes my template with out
user interaction leaving open only the merged document. Which is what I was
looking for.

Fabulous, it's great to receive feedback for this, thanks for providing
it! Feel free to stop by if you have any more questions.
 

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