Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Mail Merge
Message
From
06/06/2002 21:32:37
 
 
To
06/06/2002 13:09:34
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00665280
Message ID:
00665763
Views:
20
Fernando,

Please ignore my previous reply, I was being a bit stupid! I have got the document to merge using the following code:

local loword,odocument,lowordmaindocument

loword=createobject("word.Application")
loword.visible=.T.
lowordmaindocument="c:\ipletters\5.doc"
odocument=loword.documents.Open (lowordmaindocument, 0, 0, 0)
odocument.MailMerge.Execute

which is fine because after the document has been merged the user sometimes wants to make amendments to the document before printing. This means that we cannot include the "close without asking for save as" otherwise this executes before the user has made the amendments to the document, unless you can think of a way to include this.

I also did not include the On Error to check is Word is running because if I did it didn't seem to fire up Word at all.

But thank you for your help - it's been invaluable!

Regards

Bob
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform