Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Concatenation Challenge
Message
From
29/10/2001 14:24:38
Dragan Nedeljkovich
Now officially retired
Zrenjanin, Serbia
 
 
To
29/10/2001 11:43:57
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00574556
Message ID:
00574664
Views:
24
>I have set up a table with paths to different places on local drives and in our system where files reside that foxpro has to take action on. I am havinf trouble with copy file to syntax. I need the following line to use my table path
>
>Copy File &dty2 To \\gv-engineering\drawing\wgen\pre_pdf\hold\&dty2
>Note the above is functioning now.
>
>Desire to be
>
>Copy File &dty2 To &pdfhold + &dty2

Rule of thumb: don't use & for filenames on a system which allows for spaces in filenames, because you'll get syntax error. Use name expressions.

Second, why not
Copy File (dty2) To (forcepath(dty2,pdfhold))
I use Forcepath() a lot, because it handles the backslash for me, and handles most of the trimming of spaces (except any leading spaces in the path part: try
?'*'+FORCEPATH(" aa ", " bb ")+'*'
and you'll see you'll get all the spaces trimmed except the one before the path).

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform