Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 06-16-2010, 05:55 AM
Brandi Brandi is offline Merge to New Document - saved letter continues to ask for SQL source Windows XP Merge to New Document - saved letter continues to ask for SQL source Office 2003
Novice
Merge to New Document - saved letter continues to ask for SQL source
 
Join Date: Jun 2010
Posts: 13
Brandi is on a distinguished road
Default Merge to New Document - saved letter continues to ask for SQL source

I am using the Merge to New document button for a mail merge document and saving the letter with a name such as ABC.doc.

I need to save legal documents based on templates that can be opened at a later time for reference. The information in my Access table data source for my mail merge template changes. So, if I have saved merged information one day, it will be different the next time I use the template.



When I open my saved letters (merged documents), I am prompted to open the SQL source. I thought merging to a new document would simply save the document with the data in it and not prompt me for the data source when I open that saved document?

Do you know how I can stop this prompt? If I answer the prompt for the SQL source with Yes or No, it does open up my saved document with the data that I expect so it is not truly linking back to the data source because if it did, there would be new information in the saved letter each time.

Thank you.
Brandi
Reply With Quote
  #2  
Old 06-16-2010, 07:38 AM
Kimberly Kimberly is offline Merge to New Document - saved letter continues to ask for SQL source Windows 7 Merge to New Document - saved letter continues to ask for SQL source Office 2010 (Version 14.0)
Expert
 
Join Date: May 2010
Posts: 517
Kimberly is on a distinguished road
Default

Code:
 
Sub MergePetition()
 
Documents.Add Template:= _
"C:\Bergemann\Forfeiture\WordMailMerge\Petition.dot" _
, NewTemplate:=False, DocumentType:=0
With ActiveDocument.MailMerge
.Destination = wdSendToNewDocument
.SuppressBlankLines = True
With .DataSource
.FirstRecord = wdDefaultFirstRecord
.LastRecord = wdDefaultLastRecord
End With
.Execute Pause:=False
End With
With ActiveDocument
.AttachedTemplate = "C:\YourPathToTheNormalTemplate\Normal.dot"
End With
End Sub
Reply With Quote
  #3  
Old 06-16-2010, 08:08 AM
Kimberly Kimberly is offline Merge to New Document - saved letter continues to ask for SQL source Windows 7 Merge to New Document - saved letter continues to ask for SQL source Office 2010 (Version 14.0)
Expert
 
Join Date: May 2010
Posts: 517
Kimberly is on a distinguished road
Default

Oh yeah, I forgot you are also having a problem with .Destination, so change the macro to this instead:

Code:
 
Sub MergePetition()
 
Documents.Add Template:= _
"C:\Bergemann\Forfeiture\WordMailMerge\Petition.dot" _
, NewTemplate:=False, DocumentType:=0
With ActiveDocument.MailMerge
.Destination = 0
.SuppressBlankLines = True
With .DataSource
.FirstRecord = wdDefaultFirstRecord
.LastRecord = wdDefaultLastRecord
End With
.Execute Pause:=False
End With
With ActiveDocument
.AttachedTemplate = "C:\YourPathToTheNormalTemplate\Normal.dot"
End With
End Sub
AND, I believe it will work fine with actually changing the fake path to Normal.dot to the real path. (We just want to unattach the Petition template.)

Last edited by Kimberly; 06-16-2010 at 08:10 AM. Reason: clarification
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Merge to New Document - saved letter continues to ask for SQL source Lost Word Document and cant find it!!! I saved it but it ISNT there!! APAV Word 9 10-09-2017 01:17 PM
Outlook continues to run after I close it Shawn76 Outlook 1 08-23-2010 12:30 AM
Mail Merge data source on network drive Brandi Mail Merge 0 06-13-2010 11:26 AM
Auto Letter Hannes Word 1 10-29-2009 06:27 AM
Letter Templates happymouth Word 8 05-17-2009 02:43 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 12:06 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft