Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Help reqd for VB Macro conversion
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Help reqd for VB Macro conversion
Divers
Thread ID:
00596208
Message ID:
00596208
Vues:
54
Hi All
Can anyone please give me the correct vfp syntax for the following VB code

*!* Documents.Add Template:= _
*!* "C:\Program Files\Microsoft Office\Templates\Normal.dot", NewTemplate:= _
*!* False
*!* ActiveDocument.Footnotes.Add Range:=Selection.Range, Reference:="#"
*!* Selection.TypeText Text:="name1"
*!* ActiveWindow.ActivePane.Close
*!* Selection.TypeText Text:="This is help for name 1"
*!* Selection.InsertBreak Type:=wdPageBreak
*!* ActiveDocument.Footnotes.Add Range:=Selection.Range, Reference:="#"
*!* Selection.TypeText Text:="name2"
*!* ActiveWindow.ActivePane.Close
*!* Selection.TypeText Text:="This is help for name 2"
*!* Selection.InsertBreak Type:=wdPageBreak

I have tried many variations but cannot get the Add range to accept properly.
Object has created ok

I know it should be something like
with oWord
.ActiveDocument.Footnotes.Add ??? Then what???
endwith

.Selection.TypeText('This is text') works fine

Any help appreciated
thanks
Derek..
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform