[新手上路]批处理新手入门导读[视频教程]批处理基础视频教程[视频教程]VBS基础视频教程[批处理精品]批处理版照片整理器
[批处理精品]纯批处理备份&还原驱动[批处理精品]CMD命令50条不能说的秘密[在线下载]第三方命令行工具[在线帮助]VBScript / JScript 在线参考
返回列表 发帖

[系统相关] 帮忙修改WIN7下移动我的文档,收藏夹等等的批处理

本帖最后由 lovealei 于 2011-8-31 15:26 编辑

下面的代码是xp 下用的,WIN7下好像有些问题,主要作用是移动文件,那位大哥帮我改改,在WIN7下可以用
  1. md "D:\StoneNet\桌面"
  2. md "D:\StoneNet\Favorites\链接"
  3. md "D:\StoneNet\桌面"
  4. md "D:\StoneNet\Favorites\链接"
  5. xcopy "C:\Documents and Settings\All Users\桌面\*.*" "D:\StoneNet\桌面" /e /h /k /r /f /y
  6. xcopy "C:\Documents and Settings\Administrator\桌面\*.*" "D:\StoneNet\桌面" /e /h /k /r /f /y
  7. xcopy "C:\Documents and Settings\Administrator\Favorites\*.*" "D:\StoneNet\Favorites\" /e /h /k /r /f /y
  8. xcopy "C:\Documents and Settings\Administrator\Favorites\链接\*.*" "D:\StoneNet\Favorites\链接" /e /h /k /r /f /y
  9. xcopy "C:\Documents and Settings\All Users\Favorites\*.*" "D:\StoneNet\Favorites\" /e /h /k /r /f /y
  10. xcopy "C:\Documents and Settings\Administrator\My Documents\*.*" "D:\StoneNet\" /e /h /k /r /f /y
  11. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "Favorites" /D "D:\StoneNet\Favorites" /F
  12. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V Desktop /d "D:\StoneNet\桌面" /f
  13. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "Personal" /d "D:\StoneNet" /f
  14. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "My Music" /d "D:\StoneNet\My Music" /f
  15. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "My Video" /d "D:\StoneNet\我的视频" /f
  16. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /V Favorites /D "D:\StoneNet\Favorites" /F
  17. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /V Desktop /d "D:\StoneNet\桌面" /f
  18. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /V "Personal" /d "D:\StoneNet" /f
  19. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /V "My Music" /d "D:\StoneNet\My Music" /f  
  20. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /V "My Pictures" /d "D:\StoneNet\My Pictures" /f  
  21. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\DocFolderPaths" /v "Administrator" /d "D:\StoneNet" /f
  22. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "Common Desktop" /D "D:\StoneNet\桌面" /F
  23. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "Common Documents" /D "D:\StoneNet" /F
  24. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "Common Favorites" /D "D:\StoneNet\Favorites" /F
  25. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "CommonMusic" /D "D:\StoneNet\My Music" /F
  26. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "CommonPictures" /D "D:\StoneNet\My Pictures" /F
  27. reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /V "CommonVideo" /D "D:\StoneNet\我的视频" /F
  28. rd /s /q "C:\Documents and Settings\All Users\桌面"
  29. rd /s /q "C:\Documents and Settings\Administrator\桌面"
  30. rd /s /q "C:\Documents and Settings\Administrator\Favorites"
  31. rd /s /q "C:\Documents and Settings\Administrator\Favorites\链接"
  32. rd /s /q "C:\Documents and Settings\All Users\Favorites"
  33. rd /s /q "C:\Documents and Settings\Administrator\My Documents"
  34. echo.
  35. echo 成功的移动个人文件夹到D盘.请按任意键刷新.
  36. pause
  37. gpupdate /force
  38. goto start
复制代码

没有人帮顶啊, 主要是注册表位置,文件夹位置

TOP

好像有神马问题?

TOP

返回列表