Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Capture error from external app
Message
De
06/10/2004 10:51:30
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Capture error from external app
Divers
Thread ID:
00949207
Message ID:
00949207
Vues:
44
Hi all!

I have an application (build with vfp8) wich work toghether with other external application (v1.exe). First called second (v1.exe) with param (a video file) and second process param and create a file text with tags of file. Sometime second give a external windows error

"v1.exe has encountered a problem and need to close ...".

Some code for detail:

***********************************************************
LOCAL lcVideoFile
lcVideoFile = ALLT(Thisform.GrdDetail.txt_movie.Value)
lcVideoFile = '"'+lcVideoFile+'"'

ERASE (sys(2023)+"/vidview.txt")
SET SAFETY OFF
SET TEXTMERGE ON TO "C:\v1.bat" noshow
\CD\
\CD C:\CFIND
\v1.exe <> > <>\vidview.dat
\REN <>\vidview.dat vidview.txt
SET TEXTMERGE TO
SET TEXTMERGE OFF
SET DEFA TO SYS(2023)
SET SAFETY ON
RUN/n C:\v1.bat
****************This.runapp('C:\MEDIAINFO.BAT','','HIDDEN')
WAIT WINDOW "Gathering User Detail" NOWAIT
DO WHILE FILE(ALLT(SYS(2023))+"\vidview.txt") = .F. && wait for file to be created
* in this loop received external error
* i choose DON'T SEND for external message error
* AND MY App(VFP App) REMAIN IN THIS LOOP
ENDDO
WAIT CLEAR

SET DEFA TO (VDEF)
RETURN
***********************************************************

I wish to capture this external errors and processing internal (in rutine of vfp); and i kill external process what remaining in windows task manager (v1.exe).
GetLastError() ???

Thank's for any suggestions.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform