Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Run a windows program from within VFP6 app
Message
From
13/09/2000 11:50:25
 
 
To
13/09/2000 11:25:39
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00415851
Message ID:
00415883
Views:
23
>I want to "shell" out of a vfp6 app to run another windows based program. I know the "RUN" command supposedly will do this but it only seems to like DOS based path/command strings. Most of my directories (and others as well) often have names that are longer than 8 characters. Therefore, I can't get the RUN command to work if the target .exe has fullpath that is not DOS compliant.
>
>Is there some newer/other function I should be using instead of RUN. If I should use the RUN command is the correct syntax to put the complete target/path in a variable (i.e. cexe) and then use the "&" function (for example RUN &cexe)? Also, what is the "!" do in the RUN command?

! and RUN are equivalent.

An alternative might be to use the API_APPRUN class in the Files Section, or ShellExecute(), as implemented in _ShellExecute in the _ENVIRON.VCX in the FFC.
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
Previous
Reply
Map
View

Click here to load this message in the networking platform