Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Best way to Handle Processes
Message
 
 
To
05/11/2001 23:39:15
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00575752
Message ID:
00577787
Views:
30
>Nadya,
>
>Unless I'm missing something which is very possible, I can't see how this class would work with adist.exe &stringfile. I have got to know when the distill process is done.

Does this code work for you?
SET PROCEDURE TO Process ADDITIVE
oProcess = CREATEOBJ('API_AppRun','adist.EXE '+m.StringFile,'C:\','NOR')
*Run the application and don't wait to terminate
oProcess.LaunchApp()
*Check the exit status;  259 means still running
IF oProcess.CheckProcessExitCode() = 259
	wait window 'Still running'
ELSE
	wait window 'Terminated with a '+alltrim(str(oProcess.CheckProcessExitCode()))
ENDIF
? oProcess.KillProc()
oProcess = ''
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform