@echo off echo 修改计算机器名... set pcname=WinXP-%random:~-3% echo Windows Registry Editor Version 5.00>ComputerName.reg echo [HKEY_CURRENT_USERSoftwareMicrosoftWindowsShellNoRoam]>>ComputerName.reg echo @="%pcname%">>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlComputerName]>>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlComputerNameComputerName]>>ComputerName.reg echo "ComputerName"="%pcname%">>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlComputerNameActiveComputerName]>>ComputerName.reg echo "ComputerName"="%pcname%">>c:TempInfo.reg>>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesEventlog]>>ComputerName.reg echo "ComputerName"="%pcname%">>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlComputerNameComputerName]>>ComputerName.reg echo "ComputerName"="%pcname%">>ComputerName.reg echo [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesTcpipParameters]>>ComputerName.reg echo "NV Hostname"="%pcname%">>ComputerName.reg echo "Hostname"="%pcname%">>ComputerName.reg echo [HKEY_USERS.DEFAULTSoftwareMicrosoftWindowsShellNoRoam]>>ComputerName.reg echo @="%pcname%">>ComputerName.reg regedit /s ComputerName.reg del /q ComputerName.reg echo 修改计算机器名称完成... del %0