Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Where am I??
Message
De
29/11/2000 22:30:10
 
 
À
29/11/2000 14:03:02
Calvin Smith
Wayne Reaves Computer Systems
Macon, Georgie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00446935
Message ID:
00447181
Vues:
11
>Please bear with me because I may have missed something very basic. I cannot seem to find a command or function in VFP which will tell me with certainty where the EXE file that I am running is located. I discovered this when attempting to run an update program off a CD. If the CD is drive 'F' and the program files are copied into the windows temp directory and then run from the program operating on the CD then sys(5),curdir,sys(2014) etc all return drive 'F' or an invalid path. Can anyone give me any guidance on this, any help will be greatly appreciated...

If your main module for the app is a .PRG, you can parse the .EXE name out of the return from SYS(16,0) - if the return starts with the string "PROCEDURE ", the name of the .APP or .EXE is SUBST(SYS(16,0),AT(' ',SYS(16,0),2)+1).
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform