>>...You want to make sure that you're using my API_APPRUN class ...download it ..., and then start up an instance of Quest using launchApp - which runs the program and immediately returns control to VFP. You can periodically check the progress of the application using the object's CheckProcessExitCode() method; if returns a value other than 259, the other instance is done.
>>DO WHILE .NOT. EOF()
>>. nCNTER= nCNTER+1
>>. cCmdLineOut= Alltrim(REPORTS)
>>. oQuest=CREATEOBJECT('API_APPRUN',cCmdLineOut, "C:\Gupta\", "HIDE")
>>. =LaunchAppAndWait(cCmdLineOut, "C:\Gupta\","HIDE")
>>. Do While .T.
>>.. Wait Window NoWait "Running Quest Report Number "+ str(nCNTER)
>>.. IF oQuest.CheckProcessExitCode() != 259 && 259=ProcessRunning
>>... RELEASE oQuest
>>... EXIT
>>.. ENDIF
>>. EndDo
>>. SKIP
>>ENDDO
>Is Quest a DOS App? If so, you need to set the program to Close on Exit (go into Windows Explorer...
Yes, the DOS app is set to close on exit -
I think that the LaunchAppandWait is unaware of which process it is to wait on!
We have fully moved over to the new job tracking system and debugging the printing will have to be low priority for now.
But I would appriciate any further ideas.
Thanks Ed and George.
Ed B
Edgar L. Bolton, B.S. B.B.A.