Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
No macro expansion in COPY FILE ???
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00212150
Message ID:
00212153
Vues:
28
>Hello everyone,
>
>I'm implementing a batch download program in VFP 6 so I can store, delete, and update the files to be downloaded in a table. I'm having difficulty with the COPY FILE command within a SCAN...ENDSCAN loop.
>
>lcDestDir = "D:\MyDir\"
>SCAN
> lcFile = File_Name && from the table
> COPY FILE &lcFile TO &lcDestDir
>ENDSCAN
>
>No dice. I get the error: "File [current directory]\&lcFile does not exist." I tried enclosing the variables in parentheses as well, with the same error. Am I missing something, or does macro expansion simply not work with COPY FILE? (The docs are mum on the subject).
>
>TIA,
>-Bernie Falor
>Database Analyst
>Library Video Co.

try this

lcDestDir = "D:\MyDir\"
SCAN
lcFile = File_Name && from the table
lcsayit='Copy File '+lcfile+' to '+lcdestdir
&lcsayit
ENDSCAN


HTH
Jeff

It's Time to get a gun.

That's what I've been thinkin.

I think I can afford one, If I do a little less Drinkin.

www.TrueGeeks.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform