Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem invoking pcAnywhere (DOS)
Message
From
08/12/2002 13:37:21
 
 
To
08/12/2002 13:03:10
Henry Ravichander
RC Management Systems Inc.
Saskatchewan, Canada
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00730525
Message ID:
00730732
Views:
8
>>>>
SET CLASSLIB TO PROCESS ADDITIVE
>>>>oRun = CREATEOBJ('API_APPRUN','awremote -M=D -N="MCIB"','C:\AW','NOR')
>>>>oRun.LaunchAppAndWait()
>>>>? oRun.CheckProcessExitCode() && displays any error code issued from awremote
>>>>oRun=NULL
>
>
>>This code completely replaces your old code to create and run the batch file.
>>
>Hi Ed:
>
>I dropped your class on the form and then replaced my code with your (shown above). Ran the form and clicked the connect button which has the code in the click event.
>
>Observation:
>1. The screen that I normally used to see, which is the AWRemote DOS screen where in it displays messages such as, Last Modem Response, Dialing etc., did not show up when I ran your code. Eventually, all I saw on the calling form was the display .NULL., which I think is in response to your "? oRun.CheckProcessExitCode()". In all, there was no DOS screen that showed up. Is this expected or does it suggest a problem. Normally, once the connection is made with the agency's computers, they then initiate a call back and pick up the files form the AW directory and then resurn a Valid report.
>

This suggests (as does the further noted error message) that AWRemote did not run. If AWREMOTE is not an .EXE, but a .COM or .BAT, for example, you need to inlude the file extension in the command line.

>2. I used the debugger to see what was happenning, and noticed that "lResult = 0"; and at one point your ".icErrorMessage = 'Process specified by icCommandLine could not be started.'
>

This is what actually failed - the awremote was not started.

>Another question:
>
>In my code, the following variable collect information about where the AW directory is stored.
>
>
mawdrive = programlocation.anywaredrv
>mawdirectory = programlocation.anywaredrc
>mawpath = alltrim(mawdrive)+":\"+alltrim(mawdirectory)+"\MCIBTELE.BAT type sdf"
>mfiletorun = alltrim(mawdrive)+":\"+alltrim(mawdirectory)+"\MCIBTELE.BAT"
>mawdirtochange = "cd \"+alltrim(mawdirectory)
>
>Your Code:
>
oRun = CREATEOBJ('API_APPRUN','awremote -M=D -N="MCIB"','C:\AW','NOR')
>
>Could I replace your 'C:\AW' which is hard coded in the above code, with mAWPath, but without the MCIBTele.bat following it?

Yes.
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
Next
Reply
Map
View

Click here to load this message in the networking platform