Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Word doc
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Title:
Word doc
Miscellaneous
Thread ID:
01036250
Message ID:
01036250
Views:
44
Hi All:
I need to be able to open MS word document and merge my data source to this document without message poping up asking the user click ok to open the document as read only. Since this process needs to run at night, it creates a problem since there is not one there to click ok.

Please find my code below:

LOCAL LetterName
LetterName = "H:\charisma\MEET152\Letters\Meet152R+H_CONFO_Template.Doc"
lcspreadsheet = "E:\Temp\Excel\Test2.xls"

oWord=CREATEOBJECT("Word.Application")
oWord.WordBasic.AppMinimize(1)
oWord.VISIBLE=.T.
oWord.Documents.OPEN(LetterName)

oWord.WordBasic.MailMergeOpenDataSource(lcspreadsheet,0,0,1,0,"","",0,"","", ;
"Entire Spreadsheet", "","") *// I am having problem here merging doc.

Any idea is greatly appricated.

Thanks
MA
Next
Reply
Map
View

Click here to load this message in the networking platform