Hi Ed:
>>
SET CLASSLIB TO PROCESS ADDITIVE
>>oRun=CREATEOBJ('API_APPRUN','C:\AW\AWREMOTE.EXE -M=D -N="MCIB"','C:\AW','NOR')
>>
>>oRun.LaunchApp()
>>LOCAL mCount
>>mCount = 0
>>DO WHILE oRun.CheckProcessExitCode() = 259
>> mCount = mcount + 1
>> IF mCount < 3
>> WAIT TIMEOUT 5
>> oRun.CheckProcessExitCode()
>> ELSE
>> oRun.KillProc()
>> mCount = 0
>> endif
>>ENDDO
>>
>You're running the release copy, as opposed to what I have here - try KillProc() rather than TerminateApp().
In the Do While Loop, terminating the process after 3 attempts in about 5-10 seconds is not realistic - since it does take a while to computer. At times, the host computer many be busy - or at some point in time the transfer of files take a while. IOW what can i institute in place of waiting for 5-10 seconds before KillProc() kicks in. It would'nt be nice to introduce killProc() when pcAnywhere is transferring files. Any suggestions?
Thanks.
- Ravi
True greatness consists in being great in little things.
- Charles Simmons