Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Using Procedures and Functions
Message
De
07/05/2003 09:41:16
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
07/05/2003 08:53:35
Steven Dyke
Safran Seats USA
Texas, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00785733
Message ID:
00785765
Vues:
5
>I am trying to find the best way since the way I have done things up to this point do not always work 100 percent.
>
>For example I need to do six things:
>1. Copy a file from one directory to another(current to archive)
>2. Use Acrobat automation to mark the archive file 'Historical'.
>3. Delete the current file.
>4. Copy the new file(working to current)
>5. Use Acrobat automation to mark the current file 'Released'.
>6. Delete the working file.
>
>I have all this working but not very efficently. Some times I get an error because a file is not released before preforming an action on it.
>
>My main question is should FOpen/FClose be done within the procedure or at the calling program level?

How do you delete/copy the file? If you call a DOS command, VFP may continue executing, without waiting for the command to complete. Two workarounds are using other commands to copy/delete/etc. (for instance, API, built-in VFP commands, or RUN without the /N parameter), and using a Timer object to postpone a later action.

HTH,

Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform