copy file

J

Jaz

I want to copy a file to the desktop of all users
my script
g:
cd g:\home
copy x.txt G:\Documents and Settings\All Users\Desktop




but it gave me
G:\>script

G:\>g:

G:\>cd g:\home
The system cannot find the path specified.

G:\>copy x.txt G:\Documents and Settings\All Users\Desktop
The system cannot find the file specified.


Any help in this issue

Thanks
 
G

Guest

Try quoting the directories as follows:

copy x.txt G:\"Documents and Settings"\"All Users"\Desktop

Rgds,
Tim
 
H

Herb Martin

G:\>cd g:\home
The system cannot find the path specified.

G:\>copy x.txt G:\Documents and Settings\All Users\Desktop
The system cannot find the file specified.

Note that your CD command failed which implies that the x.txt
file is not in the current directory either.

The implication is that there is NO "\home" directory on G: --
perhaps G: is a share, with \Home as the ROOT of the share?
If so, it \Home will NOT appear on "G:" as a subdirectory (it's
really the same as the root) but this seems unlikely since you
would then expect to find you x.txt file THERE.

Whatever the case, you are apparently not in the correct directory
where the x.txt file lives.

As noted by other posters, you will also need "Quotes" around those
paths with SPACES, e.g., "G:\Documents and Settings\All Users\Desktop"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top