Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Opening other applications
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 6
Database:
Visual FoxPro
Divers
Thread ID:
00967323
Message ID:
00967330
Vues:
7
Well, Mike already covered API part :) I'll add more:
sh = CreateObject("WScript.Shell")

* note both double and single quotes around the path
* 3 means maximized window
* .F. means do not wait when the appication returns
sh.Run('"C:\Program Files\Microsoft Visual FoxPro 8\vfp8.exe"',;
	3, .F.)
Rarely this approach (Windows Scripting) may not work because of stricter security policy. Then you may use WinExec API function:
#DEFINE SW_SHOWNORMAL       1
#DEFINE SW_SHOWMINIMIZED    2
#DEFINE SW_SHOWMAXIMIZED    3

DECLARE INTEGER WinExec IN kernel32;
	STRING  lpCmdLine, INTEGER nCmdShow

= WinExec(lpCmdLine, SW_SHOWMAXIMIZED)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform