Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Word merge
Message
 
À
25/03/2004 08:01:28
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Divers
Thread ID:
00889545
Message ID:
00891136
Vues:
18
Zoran:

The problem that you have is very common when you try to handle the application using ADO.

If you change your application to handle the call directly from word the problem will be resolve because everytime the Word version change you will not need to rewrite your mail merge routine.

The way that I always deal with Mail Merge and VFP is create a macro in Word and save it in the same document that will perform the Mail Merge. Please see the Code I used in my last application.


XX=CREATEOBJECT("word.application")
XX.APPLICATION.WINDOWSTATE = 2
IF THISFORM._pageframe1.Page2.Notary_Check_box1.VALUE
XX.documents.OPEN(SYS(2003)+"\Deed_Doc_1.doc")
ELSE
XX.documents.OPEN(SYS(2003)+"\Deed_Doc_2.doc")
ENDIF
XX.APPLICATION.WINDOWSTATE = 2
XX.RUN("Deed_macro")
XX.APPLICATION.activedocument.CLOSE()
XX.QUIT
XX = ""

The data source that word create have to be in the same directory of the document. Hope this resolve your problem.
Gregorio J. Placeres
IT Analyst
Uniform Accounting Network
Auditor of State of Ohio
88 East Broad Street
P.O. Box 1140
Columbus, Ohio 43216-1140

Tel. 614-728-4694

Gregorio_J@MSN.COM

http://www.gjpproductions.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform