Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with COPY FILE command?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00799197
Message ID:
00799344
Vues:
24
I've seen some cases where copy file seems to fail every now and then. I've done something like this to get around it...

oFSO = CREATEOBJECT("Scripting.FileSystemObject")
ofso.CopyFile('fromFile','tofile')

there is a 3rd parameter (a logical) you can put in there to indicate if it should overwrite the file....so it works like this...

ofso.CopyFile(string from file, string to file, logial to overwrite)



>Has anyone run into problems using the COPY FILE command in VFP 7 SP1? I'm
>getting a "File not found" error with this command:
>
>COPY FILE (tcCustPath+"NextPKey.dbf") TO (lcSubDir+"NextPKey.dbf")
>
>Wait windows inserted before this command show that tcCustPath and lcSubDir
>contain what we expect them to, including a backslash at the end of each
>variable. The command works successfully from the command window if we
>initialize tcCustPath and lcSubDir by hand.
>
>My client has an employee who says she's had other problems with the COPY
>FILE command, and avoids using it. I haven't run into problems with COPY
>FILE until now.
>
>I'm going to their site tomorrow to see if I can figure this out.
ICQ 10556 (ya), 254117
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform