Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Word OLE kick-start...
Message
 
À
09/08/1997 06:44:06
Jean-Pierre Overbeek
New Limit Database Solutions
Amsterdam, Pays-Bas
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00043859
Message ID:
00043872
Vues:
40
>Hello,
>
>Is there anybody who can help met kick-start with Word-Ole, because I need to fill the company name in a Word order document. Can I use the word fields, or is there a better way???
>
>Please help, any word ole example is appreciated...
>TIA
>Greetings,
>Jean-Pierre

Here word ole that use to open a file. I hope it can help you.

MyOLe = CREATEOBJECT("Word.Basic")

lsLanguage = MyOLe.appInfo(16) && Test if Word is french or english
DO CASE
CASE lsLanguage = "Français"
lsFileOpen = "MyOLe.FichierOuvrir"
lsAppMinimize = "MyOLe.FenAppRéduction"
lsAppActivate = "MyOLe.AppActiver"

CASE lsLanguage = "English"
lsFileOpen = "MyOLe.FileOpen"
lsAppMinimize = "MyOLe.AppMinimize"
lsAppActivate = "MyOLe.AppActivate"

OTHERWISE

RETURN
ENDCASE

MyFile = "c:\temp\temp.doc"
MyFile = ["] + MyFile + ["]

&lsFileOpen. (MyFile, 0) && Modele, nouvModel

bMyMinimize = IIF (&lsAppMinimize.() = 0, .F., .T.)
IF bMyMinimize
&AppMinimize. && Fera un restore
ENDIF
&lsAppActivate. ("",1) && le 1 indique le moment, 1 -> now
Analystik Team
1430 Belanger
Montreal (Quebec)
Canada
(514) 278-2727
analyste@analystik.ca
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform