Move command help!

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
BatMaster
Posts: 28
Joined: 22 Dec 2010 12:53

Move command help!

#1 Post by BatMaster » 03 Oct 2011 10:56

hey guys
two Questions for you
1.why does the move command treat spaces as "to"?
AND
2.i need to move a file to another folder but the folders name has spaces :( in it and i need admin rights to rename it. is there anyway i can still use the move command to move it :?:

aGerman
Expert
Posts: 4678
Joined: 22 Jan 2010 18:01
Location: Germany

Re: Move command help!

#2 Post by aGerman » 03 Oct 2011 11:02

1. Because space is one of the standard delimiters in batch AND that's the syntax for MOVE
2. Enclose the entire path in quotes like

Code: Select all

move "c:\path with spaces\file.ext" "c:\path with more spaces\new file name.ext"


Regards
aGerman

BatMaster
Posts: 28
Joined: 22 Dec 2010 12:53

Re: Move command help!

#3 Post by BatMaster » 03 Oct 2011 11:08

Thanks aGerman

Post Reply