From Access- Saving a Mail Merge document

M

Marsela

Hi!

I have problem saving a Mail Merge document automatically
from an Access Form using VBA code.

Situation:
I have a form for mail merge and email.
I can create the mailmerge (Insurance Application form
with Organizer name), no problem, and i can send email
with code using attachment or anything else.
After merging the document I want to save the merged file
in a spesific location with a specified name and after
that i can send the merged documents as attachment.
Again, the only problem is saving the merged file as word
document without opening it (i need automatically). ( i
don't want any other code).

f.ex after I execute the mailmerge how can i save this
merged object as word document....

Note: I have the code for mailmerge (Using database
information) and i have the code for sending email.

Thanks everybody for your time.

Marsela
 
M

Marsela

I got the solution:

My new document is
dim doc as word.document
and ...
...
after merged
we have

doc = GetObject(Word.ActiveDocument)
doc.SaveAs "c:\path...\applicationform.doc"

it works great..

Marsela
 

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