Information générale
Catégorie:
COM/DCOM et OLE Automation
Titre:
Mailmerge with Word 2007
Versions des environnements
Network:
Windows 2008 Server
Hi
I am using Word 2007 and Excel 2007
My VFP 9 program attempts to call Word to perform mailmerge with following lines of code but encounter message that it cannot locate the XLS file.
Is there anyway to setup Word 2007 so that it will look for XLSX file or CSV file instead of XLS file
Would really appreciate if you could share your expertise.
Thanks & Best Regards
DECLARE INTEGER ShellExecute IN Shell32.DLL INTEGER hwnd, ;
STRING @lpOperation, STRING @lpFile, STRING @lpParameters, ;
STRING @lpDirectory, INTEGER nShowCmd
lcParms = ""
lcDir = addbs(toApplication.ProjectDirectory)+'DOCS'
lcFile = alltrim(juststem(lcOutputFileName))+'.DOC'
lcOp = 'open'
lnshow = 3
lnError = ShellExecute(0, @lcop, @lcfile, @lcparms, @lcdir, lnshow)
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement