@echo off mode con cols=71 lines=5 title “我的文档、桌面、收藏夹”转移D盘 http://www.pc6.com/ for /l %%a in (1,1,8) do ( echo/ echo\ echo. echo ********************************************************************** echo **********************“我的文档”大挪移****************************** echo ***************************作者:何雷********************************* color 1f ping -n 1 127.1>nul color 1f ping -n 1 127.1>nul cls ) for /l %%a in (1,1,8) do ( echo/ echo\ echo. echo ********************************************************************** echo ************************载入内存,耐心等候!************************** echo ********************************************************************** color 2f ping -n 1 127.1>nul color 2f ping -n 1 127.1>nul cls ) md "E:\My Documents" md "E:\My Documents\Favorites" md "E:\My Documents\Desktop" reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Favorites" /t reg_sz /d "E:\My Documents\Favorites" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Personal" /t reg_sz /d "E:\My Documents" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Music" /t reg_sz /d "E:\My Documents\My Music" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Pictures" /t reg_sz /d "E:\My Documents\My Pictures" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "Favorites" /t reg_sz /d "E:\My Documents\Favorites" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "Personal" /t reg_sz /d "E:\My Documents" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "My Music" /t reg_sz /d "E:\My Documents\My Music" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "My Pictures" /t reg_sz /d "E:\My Documents\My Pictures" /f reg add "HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Download Directory" /t reg_sz /d "E:\My Documents" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Desktop" /t reg_sz /d "E:\My Documents\Desktop" /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /v "Desktop" /t reg_sz /d "E:\My Documents\Desktop" /f for /l %%a in (1,1,8) do ( echo/ echo\ echo. echo ********************************************************************** echo **************************正在转移文件!****************************** echo ********************************************************************** color 1f ping -n 1 127.1>nul color 1f ping -n 1 127.1>nul cls ) if exist c:\windows\system\Dxdiag.exe goto 98 xcopy C:\Docume~1\%USERNAME%\Mydocu~1\*.* E:\Mydocu~1\ /e /y xcopy C:\Docume~1\%USERNAME%\Favori~1\*.* E:\Mydocu~1\Favori~1\ /e /y xcopy C:\Docume~1\%USERNAME%\"桌面"\*.* E:\Mydocu~1\Desktop\ /e /y goto end :98 xcopy C:\Mydocu~1\*.* E:\Mydocu~1\ /e /y xcopy C:\WINDOWS\Favori~1\*.* E:\Mydocu~1\Favori~1\ /e /y xcopy C:\WINDOWS\Desktop\*.* E:\Mydocu~1\Desktop\ /e /y :end cacls rd /s /q C:\Docume~1\%USERNAME%\Mydocu~1\ rd /s /q C:\Docume~1\%USERNAME%\Favori~1\ rd /s /q C:\Docume~1\%USERNAME%\"桌面"\ taskkill /f /im explorer.exe for /l %%a in (1,1,8) do ( echo/ echo\ echo. echo ********************************************************************** echo ************************转移完毕,正在启动桌面!********************** echo ********************************************************************** color cf ping -n 2 127.1>nul cls ) start %SystemRoot%\explorer.exe for /l %%a in (1,1,8) do ( echo/ echo\ echo. echo ********************************************************************** echo ********************感谢使用,您的电脑将重新启动!********************* echo ********************************************************************** color cf ping -n 1 127.1>nul color fc ping -n 1 127.1>nul cls ) echo. echo [我的文档、桌面、收藏夹]已转移到[E:\My Documents],将重新启动! pause shutdown -r -t 0