Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Pascal Borland > Re: Moving/relo...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 5 Topic 1041 of 1118
Post > Topic >>

Re: Moving/relocating a file

by "Rick Davey" <rdavey@[EMAIL PROTECTED] > Jul 6, 2007 at 12:41 PM

OK Got it.

     ExecString := '/c copy C:\Path\Filename.txt 
\\Server\Path\NewFilename.txt';
     SwapVectors;
     Exec(GetEnv('COMSPEC'),ExecString);
     SwapVectors;

I am using variables in place of the paths and filenames in the
ExecString, 
and find that if either includes spaces, you must enclose in a double
quote.

Thanks all.

"Rick Davey" <rdavey@[EMAIL PROTECTED]
> wrote in message 
news:f6lk6i$9bu$1@[EMAIL PROTECTED]
> What's the Pascal code to move a file?  I need to move it to another
drive 
> (possibly a UNC path).
> Thanks in advance!
>
 




 5 Posts in Topic:
Moving/relocating a file
"Rick Davey" &l  2007-07-06 10:39:19 
Re: Moving/relocating a file
winston19842005 <bjjly  2007-07-06 11:11:21 
Re: Moving/relocating a file
"Rick Davey" &l  2007-07-06 11:47:31 
Re: Moving/relocating a file
"Rick Davey" &l  2007-07-06 12:41:32 
Re: Moving/relocating a file
Bart <broersma.juda_AN  2007-07-07 16:45:33 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu Jul 24 23:42:51 CDT 2008.