Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Copy file + variable, error
Message
De
04/08/2008 09:15:58
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
Divers
Thread ID:
01336220
Message ID:
01336228
Vues:
15
This message has been marked as a message which has helped to the initial question of the thread.
>I teste
>
>
>COPY FILE &anxFullPth TO "DADOS\ENVIO.DBF"
>
>works fine
>
>
>Then
>
>txtPathName = "DADOS\ECT\" + "ECT" + CHRTRAN(DTOC(DATE()),"/","") + ".TXT"
>COPY FILE &anxFullPth TO txtPathName

In addition to the other advice you've been given, consider using the FORCEPATH() and FORCEEXT() functions to build your file name:

txtPathName = FORCEEXT(FORCEPATH("ECT" + CHRTRAN(DTOC(DATE()),"/",""), "DADOS\ECT"), "TXT")

That way, you don't have to be sure to get all the punctuation right. In my view, it's more readable, as well. Certainly, it makes the intent clearer.

Tamar
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform