Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP and word97 error
Message
De
02/05/1998 14:31:20
 
 
À
02/05/1998 14:15:37
Anderson Girardi
Athenas Automação de Escritório
Porto Alegre, Brésil
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00095638
Message ID:
00096527
Vues:
27
>Hello Alexander Grigorjev,
>
>Nowly i did what you saw but i'm yet have problem now the VFP shows me a message saying "Missing operand"
>
>Do you know are can be?
>
>Thank you very much
...snip
>
>Anderson Girardi
>

Hello Anderson Girardi,

try the following code:

PUBLIC oWordDocument RegistroEdital
#define wdFieldDocVariable = 64 && as defined in MS Word VB
...
oWordDocument=createobject("word.application") && Create word object
with oWordDocument
.Documents.Open("c:\athenas\ath_lici\teste.doc")
.ActiveDocument.variables("Cidade").value = "Porto Alegre"
oRange=.ActiveDocument.Range(0,0)
.ActiveDocument.Fields.Add(oRange, wdFieldDocVariable, "Teste1")
.ActiveDocument.variables("Teste1").value = "Anderson Reis Girardi"

*-- no need for FOR loop
*-- For ix= 1 to .ActiveDocument.Fields.count
*-- .ActiveDocument.Fields(ix).Update
*-- Next
*-- no need for FOR loop
.ActiveDocument.Fields.Update
.visible = .t. && Show word app - Word 7.0 support
endwith
...

Good Luck

Alexander
Alex
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform