Home > OS >  Great god a batch
Great god a batch

Time:09-18

Windows 7 (32-64) by modifying the registry changes under the specified under Windows update server update location address http://192.168.0.1

@ echo off & amp;
If exist "% SystemRoot % \ SysWOW64" set Sys=64
Set the Key=HKCU \ Software \ Microsoft \ Windows \ CurrentVersion \ Group Policy Objects \ Machine \ Software \ Policies \ Microsoft \ Windows \ WindowsUpdate

Call: Setting
Set the Key in registry Key HKLM \ SOFTWARE \=Policies \ Microsoft \ Windows \ WindowsUpdate

Call: Setting

If "% % Sys"=="64" (

Set the Key in registry Key HKLM \ SOFTWARE \=Wow6432Node \ Policies \ Microsoft \ Windows \ WindowsUpdate

Call: Setting

)

The exit



: Setting

Reg the add Key "% %" REG_SZ "WUServer"/t/d/v/f
"http://192.168.0.1"
Reg the add Key "% %" REG_SZ "WUStatusServer"/t/d/v/f "192.168.0.1"

Goto: eof

Tried many times and found that each registry under corresponding value is different, a batch can't do all the specified address, please advise how to edit the batch,

CodePudding user response:

Where not to corresponding
  • Related