Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Nocturnal print via MUTEX and Run-App-and-Wait
Message
De
11/09/1999 19:12:57
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00254699
Message ID:
00263724
Vues:
25
>Hello Ed,
>
>After running through the process line by line in debug I was able to determine that the problem was not with code but with call recognition...
>
>The object is created for a DOS command line ( the command line launches another application "Quest" ) and then the DOS command line object closes which allows for the next command line run! The Quest App is still running, 'big problems'.
>

Why not just launch the Quest application directly?

>Can I determine the windows-handle for Quest to force the WAIT to be for it?
>
>>>
>>>...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.
>>>
>>>Paste Edgar's code here:
>>>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
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
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform