Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
TMP files hanging around..
Message
 
À
05/09/1997 10:53:40
Gino Miceli
Lan Professionals, Inc.
Bay Shore, New York, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00048372
Message ID:
00048714
Vues:
22
>Thank you for your reply...
>
>>>I have a 'launcher' application run my APP. This controlling EXE creates a cursor or two while loading. Since this EXE does not get control back from the APP, it never cleans up after itself (the TMP files). How can I force it to clean up these files?
>
>
>>
>>It depends on whether the TMP files being left behind are the result of creating the cursors or temporary files that FoxPro creates
>
>They're created because of temporary cursors. I have already tried doing a CLOSE ALL, but that doesn't do it. It only cleans up AFTER the controlling EXE exits! This is a problem when I have abnormal termination, and since the called APP never returns control (I dont do that to ensure finickey FoxPro quits)
>
>>
>>I took the solution to this problem a step further. On startup, my application creates a batch file to delete left behind TMP files. If the user exits normally, the shutdown routine deletes it. However, if they exit by either re-booting or turning the machine off, the batch file is left behind. My installation routine inserts lines in the user's AUTOEXEC.BAT to look for the file, and if present execute it. If it's found, AUTOEXEC.BAT will delete it after execution.
>
>A very clever solution. This is my biggest complaint about VFP. I hate the fact that every simple (or what should be simple) task has to become a big song and dance. I'm sure MS spent plenty of time on the DB engine of VFP, but I think they need to spend at least as much time if not more on the front end!

Actually, the solution was implemented back in FPD 2.5 initially and ported to FPW. If I understand correctly, the TMP files are the ones created by VFP when it starts. The other part of the solution, creating a procedure or non-visual class in the launcher, to handle the shutdown, should work. It actually can be helpful to do it this way, since there's only one place in your system through which the exit can occur. Your apps will benefit by being smaller, and, when and if, a change is required, you only have to turn over the launcher, and not all the individual apps.

George
George

Ubi caritas et amor, deus ibi est
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform