Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Using shellexecute in .prg file.. Shell Execute Can't Fi
Message
 
 
À
23/10/2004 21:26:44
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 6 SP3
Divers
Thread ID:
00954044
Message ID:
00954089
Vues:
19
>Running into a problem that I cannot find a solution for. In order to run a particular executable from a .prg file over a network without mapping a drive letter (using a UNC path), I need to run the program file from shellexecute. No problem there. The problem comes from the fact the Visual FoxPro wants to just keep going before the program shellexecute started finishes. I need a way to allow the program (pkzip) to complete without the user having to hit a key (required with the wait command.)
>
>Question... Is there a way to allow the shellexecute command to finish before the .prg file continues? Without having to use WAIT?
>

Hi Jack,

The ShellExecute() doesn't wait for application it launches to complete but returns control to VFP immediately. You can use API_APPRUN in .VCX form File #9477 to launch Zip program and wait for it completition. Or you can use WSH Run() method to do the same. See Re: API_AppRun Message #796097 and Re: ShellExecute() does not complete b/4 message after is di Message #867312.
As alternative, you can use some third patrty tool, other than PKZIP, that works from within VFP as ActiveX or DLL. You'll find quite a few sample classes and programs for zipping/unzipping in UT Download area.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform