Change the Product Key for Windows XP SP1

There are two methods that people can apply to change the Product Key with the Volume Licensing media after installation.
Volume License Key (VLK) is a term used by computer software vendors to display product keys when installing software licensed under Volume Licensing that allows the use of a single key for many installations.

There are two methods that people can apply to change the Product Key with the Volume Licensing media after installation. The first method is to use the graphical interface (GUI) Windows Activation Wizard, and the second method is to use commands in Windows Management Instrumentation (WMI).

The method of using Windows Activation Wizard is simpler than using the command line. Use this method in case you only have a few computers that need to change the Product Key. But in case you need to change the Product Key for multiple computers, the command method is the most effective method.

Use Windows Activation Wizard

Note: Before performing the following operations, you need to create a restore point in System Restore in case there is a problem with the system.

You do the following:
  1. Click Start | Run .
  2. In the Open box, type Regedit and then click OK .
  3. Then the Registry Editor window will appear. In the left panel, go to the following key:

    HKEY_LOCAL_MACHINESoftwareMicrosoftWindowsNTCurrent VersionWPAEvents
  4. In the right panel, right-click OOBETimer and select Modify .
  5. Change at least some of this value to deactivate Windows.
  6. Click on the Start menu | Run .
  7. In the Open box, enter the following command and click OK :

    % systemroot% system32oobemsoobe.exe / a
  8. Click on Yes, I want to phone a customer service representative to activate Windows and then click Next .
  9. Click Change Product Key .
  10. Enter the new Product Key in the New key boxes and click Update . If you return to the previous window, click Remind me later and then restart the system.
  11. Repeat steps 6 and 7 to reactivate Windows. When you successfully activate, you will receive the message Windows is already activated . Click OK to exit the wizard.
  12. Click OK .
  13. Install SP1 for Windows XP.
Use script

You can create a WMI script to change the VLK, then deploy this script in a startup script. The sample ChangeVLKey2600.vbs script and ChangeVLKeySP1.vbs script described in this section will use a new VLK that you want to import. Microsoft recommends using the ChangeVLKey2600.vbs script for non-SP1 Windows XP computers and using the ChangeVLKeySP1.vbs script on computers that use the SP1 version of Windows XP. These two scripts perform the following functions:
  1. Delete the dash character (-) from the 5-part Product Key string.
  2. Create a win32_WindowsProductActivation class. They will call the SetProductKey function with the new VLK.
You can create a batch file or a CMD file using one of the new Product Key template scripts as an argument and then deploy it as part of a boot script or run it from the command line instead. Change the Product Key on a computer.

The ChangeVLKeySP1.vbs file contains the following code:

WMI Script - ChangeVLKey.vbs

Script này thay đổi được khóa product trên máy tính

************************************************** *************************
[netshelter] ON ERROR RESUME NEXT
if Wscript.arguments.count
Wscript.echo "Script can't run without VolumeProductKey argument"
Wscript.echo "Correct usage: Cscript ChangeVLKey.vbs ABCDE-FGHIJ-KLMNO-PRSTU-WYQZX"
Wscript.quit
end if
Dim VOL_PROD_KEY
VOL_PROD_KEY = Wscript.arguments.Item (0)
VOL_PROD_KEY = Replace (VOL_PROD_KEY, "-", "") remove hyphens if any
for each Obj in GetObject ("winmgmts: {impersonationLevel = impersonate}"). InstancesOf ("win32_WindowsProductActivation")
result = Obj.SetProductKey (VOL_PROD_KEY)
if err <> 0 then
WScript.Echo Err.Description, "0x" & Hex (Err.Number)
Err.Clear
end if
next
The ChangeVLKey2600.vbs script has the following code:

WMI Script - ChangeVLKey.vbs

Script này thay đổi được khóa product trên máy tính

************************************************** *************************
ON ERROR RESUME NEXT
if Wscript.arguments.count
Wscript.echo "Script can't run without VolumeProductKey argument"
Wscript.echo "Correct usage: Cscript ChangeVLKey.vbs ABCDE-FGHIJ-KLMNO-PRSTU-WYQZX"
Wscript.quit
end if
Dim VOL_PROD_KEY
VOL_PROD_KEY = Wscript.arguments.Item (0)
VOL_PROD_KEY = Replace (VOL_PROD_KEY, "-", "") remove hyphens if any
Dim WshShell
Set WshShell = WScript.CreateObject ("WScript.Shell")
WshShell.RegDelete "HKLMSOFTWAREMicrosoftWindows NTCurrentVersionWPAEventsOOBETimer" 'delete OOBETimer registry value
for each Obj in GetObject ("winmgmts: {impersonationLevel = impersonate}"). InstancesOf ("win32_WindowsProductActivation")
result = Obj.SetProductKey (VOL_PROD_KEY)
if err <> 0 then
WScript.Echo Err.Description, "0x" & Hex (Err.Number)
Err.Clear
end if
next
For example, to use the ChangeVLKeySP1 script from the command line, go to the Start menu and enter the following command in the Run box and click OK:
c: changevlkeysp1.vbs ab123-123ab-ab123-123ab-ab123
In which AB123-123AB-AB123-123AB-AB123 is the new Product Key to use.
4.3 ★ | 4 Vote