a06lp Posted September 23, 2004 Posted September 23, 2004 Hi,I'm trying to move (From %UserProfile% to %AllUserProfile%):-All menus, submenus, and shortcuts from Start Menu-All Shortcuts from DesktopBasically, I don't want anything in the %UserProfile% folders of Start Menu and Desktop, when all my programs finish installing. I want it all in %AllUserProfile%.The problem is that ONLY the desktop *.lnk files are moving, but NOTHING ELSE. Not even the regular .lnk files in the Start Menu (and not submenus either).Am I doing something wrong?This is my batch file:MOVE "%UserProfile%\Desktop\*.*" "%AllUsersProfile%\Desktop\"MOVE "%UserProfile%\Start Menu\*.*" "%AllUsersProfile%\Start Menu\"
MHz Posted September 23, 2004 Posted September 23, 2004 Move /?Moves files and renames files and directories.This means no recursing with folders, so you may need to do a command for every folder?
a06lp Posted September 23, 2004 Author Posted September 23, 2004 any suggestions for a better way to accomplish what im trying to do?
MHz Posted September 23, 2004 Posted September 23, 2004 XCOPY /S /H /R /Y "%UserProfile%\Desktop" "%AllUsersProfile%\Desktop\"XCOPY /S /H /R /Y "%UserProfile%\Start Menu" "%AllUsersProfile%\Start Menu\"Then useDEL /S /Q "%UserProfile%\Desktop\*.lnk"DEL /S /Q "%UserProfile%\Start Menu\*.lnk"That may do it. You can double check the switches and syntax, to make sure that they are ok for you.The delete command may take out accessories as well. You will need to exclude them somehow.
a06lp Posted September 23, 2004 Author Posted September 23, 2004 I ran the above, and all shortcuts were copied (not folders or in-use files, which is fine, because none of those will be there on first boot) from the desktop.as far as the start menu - all links were copied, and then deleted from UserProfile, BUT the directories remain...However, this code copies everything, the removes the entire UserProfile start menu:XCOPY /S /H /R /Y "%UserProfile%\Desktop" "%AllUsersProfile%\Desktop\"XCOPY /S /H /R /Y "%UserProfile%\Start Menu" "%AllUsersProfile%\Start Menu\"DEL /S /Q "%UserProfile%\Desktop\*.lnk"RD /S /Q "%UserProfile%\Start Menu\" Now everything is managable, and in one place.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now