Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Open DBF into Word Table
Message
De
30/12/2005 08:48:01
 
 
À
30/12/2005 05:28:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01081960
Message ID:
01081975
Vues:
6
>Dear Experts
>
>Is it possible to copy a DBF to word table?
>After applying commands
>Word document should automatically open with table
>Alongwith column lines.
>

There are a couple of ways to do this. The fastest is probably to copy the DBF to a CSV file and then open that file in Word and convert it to a table. Something like this (totally untested):
USE YourTable
COPY TO YourTable TYPE CSV

oWord = CREATEOBJECT("Word.Application")

* Add the complete path in the next line
oDoc = oWord.Documents.Open("YourTable.CSV")
oRange = oDoc.Range()

oRange.ConvertToTable(",")

oWord.Visible = .T.
Tamar
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform