Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Word Automation - Programatic selection of data source
Message
De
12/03/2008 16:49:24
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows 2000 SP4
Network:
Novell 6.x
Database:
Visual FoxPro
Divers
Thread ID:
01297070
Message ID:
01301563
Vues:
11
>>I have some coding for automation between FDP and word. I create a data source, merge the document, etc. Is there any way to code the program to tell word a specific location of a data source to use to merge into the word document template?
>
>
>oWord = CREATEOBJECT([Word.Application])
>oActiveDoc = oWord.Documents.Open([some document])
>WITH oActiveDoc.MailMerge
>     .MainDocumentType = 0 && Letter if my mind serves me well
>     .OpenDataSource([Some other document that should be used as a source for MailMegre],1,.f.)
>ENDWITH
>
The .opendatasource worked fine for me on my PC, although I found that certain machines would get an OLE error saying there was no data source for the document. They are running the same version of word with the same service pack and same OS. What can these certain machines be missing which would cause the command to not work from their machines?
``` Appreciate a normal day, it is always better than a bad one ```

Kev
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform