N
Nathan Franklin
Hey Guys..
I am trying to complete an automated mail merge.. It goes through
successfully, but because I have the mail merge destination to a new
document, it creates a new document for the output of the mail merge. If
possible i need the output to stay on the current document... I have tried
ommiting the Destination property and it still launches a new document. Even
if I cant get it to stay on the current document... how do i reference the
new document??
When I first create a document, I create a new document from a tremplate
Doc = App.Documents.Add(Application.StartupPath() & "\template.dot",
Visible:=True)
This loads a new document into the doc variable formated to my template. So
I would like the mailmerge to store into the document that is in the doc
variable.....
A copy of my code is below...
MailMerge = Doc.MailMerge
MailMerge.OpenDataSource(Name:=Application.StartupPath() &
"\temp\merge.doc", LinkToSource:=True, AddToRecentFiles:=False)
MailMerge.Destination = Word.WdMailMergeDestination.wdSendToNewDocument
MailMerge.Execute(False)
Thanks very much
Nathan
I am trying to complete an automated mail merge.. It goes through
successfully, but because I have the mail merge destination to a new
document, it creates a new document for the output of the mail merge. If
possible i need the output to stay on the current document... I have tried
ommiting the Destination property and it still launches a new document. Even
if I cant get it to stay on the current document... how do i reference the
new document??
When I first create a document, I create a new document from a tremplate
Doc = App.Documents.Add(Application.StartupPath() & "\template.dot",
Visible:=True)
This loads a new document into the doc variable formated to my template. So
I would like the mailmerge to store into the document that is in the doc
variable.....
A copy of my code is below...
MailMerge = Doc.MailMerge
MailMerge.OpenDataSource(Name:=Application.StartupPath() &
"\temp\merge.doc", LinkToSource:=True, AddToRecentFiles:=False)
MailMerge.Destination = Word.WdMailMergeDestination.wdSendToNewDocument
MailMerge.Execute(False)
Thanks very much
Nathan