in reply to Moving folders to new directory location

I need to move C:\Documents and Settings\Ryan-Laptop(user) to the new location without compromising any files.

Then do as Corion suggested and use

system q[xcopy /E /O /K C:\Documents and Settings\Ryan-Laptop(user) U: +\newName];

as any other method (including Win32::CopyFile()), will compromise the files by not copying their security attributes (ACLs etc.).

Read the help for xcopy to find out why /O is important. You might also want /X


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
RIP an inspiration; A true Folk's Guy

Replies are listed 'Best First'.
Re^2: Moving folders to new directory location
by rovf (Priest) on Jun 24, 2010 at 07:48 UTC
    Nearly correct. We need to DOS-quote the argument, because of the embedded spaces.

    BTW, though not necessary in the concrete example, I think it would be a good idea to always use \\ instead of \ even withing q[...], because this will be needed anyway when directories are specified by using UNC pathes.

    -- 
    Ronald Fischer <ynnor@mm.st>