Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
API _APIRUN
Message
From
31/03/1999 07:17:16
 
 
To
31/03/1999 03:48:24
Fida Shamsoodeen
Combined Systems (Pty) Ltd
Centurion, South Africa
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Title:
Miscellaneous
Thread ID:
00203779
Message ID:
00203798
Views:
17
>Can anyone please help with this.
>
>I am using api_apirun from with VFP 6.00.
>FOR EXAMPLE : I call notepad.exe.
>The problem is when I exit notepad, I still get the wait window
>"still Running".
>
>Is there a way to get rid of the wait window after I have
>exited notepad without pressing Enter.
>

Can you show the code you're using to run this that causes a problem? There's no WAIT WINDOW in the class; if you're using the example code as a basis for getting it to work, there's no need for it. The following will run notepad; the first runs and returns immediately to VFP, the second does not return to VFP until it finishes:

SET CLASSLIB TO PROCESS
oProc = CREATEOBJ('API_APPRUN','NOTEPAD.EXE MyFile.TXT')
oProc.LaunchApp()
* Notepad is running independent of VFP; you can check it's state with
* oProc.CheckProcessExitCode(); it's done when you get a value other than 259
oProc2 = CREATEOBJ('API_APPRUN','NOTEPAD.EXE OtherFile.TXT')
oProc2.LaunchAppAndWait()
* Control will not return to VFP until the second instance of Notepad
* is closed (it doesn't matter what happened to the first) or until
* you've pressed the < Esc > key with VFP as the active process.
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