通过脚本修改xp的cd key
http://www.larkmoon.com/read.php/45.htm
ON ERROR RESUME NEXT
Dim VOL_PROD_KEY
if Wscript.arguments.count<1 then
VOL_PROD_KEY=InputBox("Message1"&vbCr&vbCr&"Message2","The Title","UserInput, key")
if VOL_PROD_KEY="" then
Wscript.quit
end if
else
VOL_PROD_KEY = Wscript.arguments.Item(0) ‘Get usr input from command line
end if
VOL_PROD_KEY = Replace(VOL_PROD_KEY,"-","") ‘Remove hyphens if any
‘WMI
for each Obj in GetObject("winmgmts:{impersonationLevel=impersonate}").InstancesOf ("win32_WindowsProductActivation")
result = Obj.SetProductKey (VOL_PROD_KEY) ’Update key
if err = 0 then
Wscript.echo "OK!"
end if
if err 0 then
Wscript.echo "Failed"
Err.Clear
end if
Next
