Article ID: 328874 - Last Review: November 6, 2008 - Revision: 8.1 How to change the Volume Licensing product key on a computer that is running Windows XP Service Pack 1 and later versions of Windows XP This article was previously published under Q328874 Warning The steps in the article are effective only on Volume License media. If you try these steps on OEM media or on retail media, you will not change the product key. If you use a "leaked" product key (a product key that is known to be available to the public) to deploy Windows XP across multiple computers (a Volume Licensing installation), you might be unable to install Windows XP Service Pack 1 (SP1) and later versions of Windows XP, or automatically obtain updates from the Windows Update Web site. For example, you might receive the following error message when you install Windows XP SP1 and later versions of Windows XP: The Product Key used to install Windows is invalid. Please contact your system administrator or retailer immediately to obtain a valid Product Key. You may also contact Microsoft Corporation's Anti-Piracy Team by emailing piracy@microsoft.com if you think you have purchased pirated Microsoft software. Please be assured that any personal information you send to the Microsoft Anti-Piracy Team will be kept in strict confidence. This article is intended for an advanced computer user. You might find it easier to follow the steps if you print this article first. Prerequisites You must have a valid product key before you can use the information in this article. To obtain a valid product key, click the following link to contact the Microsoft Volume Licensing Service Center: https://www.microsoft.com/licensing/servicecenter/home.aspx (https://www.microsoft.com/licensing/servicecenter/home.aspx) Steps to change the volume licensing product key This article describes two methods for how to change the Windows XP product key after a Volume Licensing installation to resolve the issue. One method uses the Windows Activation Wizard graphical user interface (GUI) and the other method uses a Windows Management Instrumentation (WMI) script. The Activation Wizard method is easier. However, if you must change the product key for multiple computers, the script method is more suitable. Method 1: Use the Activation Wizard Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base: 322756 (http://support.microsoft.com/kb/322756/ ) How to back up and restore the registry in Windows If you only have a few volume licensing product keys to change, you can use the Activation Wizard. Note We recommend that you run System Restore to create a new restore point before you follow these steps. Deactivate Windows 1. Click Start, and then click Run. 2. In the Open box, type regedit, and then click OK. 3. In the navigation pane, locate and then click the following registry key: HKEY_LOCAL_MACHINE\Software\Microsoft\WindowsNT\Current Version\WPAEvents 4. In the topic pane, right-click OOBETimer, and then click Modify. 5. Change at least one digit of this value to deactivate Windows. Reactivate Windows and add new product key 1. Click Start, and then click Run. 2. In the Open box, type the following command, and then click OK. %systemroot%\system32\oobe\msoobe.exe /a 3. Click Yes, I want to telephone a customer service representative to activate Windows, and then click Next. 4. Click Change Product key. 5. Type the new product key in the New key boxes, and then click Update. If you are returned to the previous window, click Remind me later, and then restart the computer. 6. Repeat steps 1 and 2 to verify that Windows is activated. You receive the following message: Windows is already activated. Click OK to exit. 7. Click OK. 8. Install Windows XP Service Pack 1a or a later version of Windows XP. If you cannot restart Windows after you install Windows XP SP1 or a later version of Windows XP, try the following steps: 1. Restart your computer and start pressing F8 until you see the Windows Advanced Options menu. 2. Select Last Known Good Configuration from the menu and press ENTER. This option starts Windows by using a previous good configuration. 3. Repeat steps 1 through 8 under "Reactivate Windows and add new product key." If you can install SP1 or a later version of Windows XP and you can restart Windows, you have resolved the issue. If the issue has not been resolved, try method 2 or see the "Next Steps" section for more troubleshooting resources. Method 2: Use a script If you must change the product key for multiple computers, we recommend this method. You can create a WMI script that changes the volume licensing product key, and then deploy this script in a startup script. The sample ChangeVLKey2600.vbs script and the sample ChangeVLKeySP1 script that are described in this section use the new volume licensing key that you want to enter as a single argument. It is in a five-part alphanumeric form. We recommend that you use the ChangeVLKey2600.vbs script on Windows XP-based computers that are not running Windows XP SP1 and later versions of Windows XP and that you use the ChangeVLKeySP1.vbs script on Windows XP-based computers that are running Windows XP SP1 and later versions of Windows XP. These scripts perform the following functions: They remove the hyphen characters (-) from the five-part alphanumeric product key. They create an instance of the win32_WindowsProductActivation class. They call the SetProductKey method with the new volume licensing product key. You can create a batch file or a cmd file that uses either of the following sample scripts, together with the new product key as an argument. You can deploy it as part of a startup script or run it from the command line to change the product key on a single computer. Examples For more information about how to script the product key, visit the following Microsoft Web site: http://technet.microsoft.com/en-us/library/bb457096.aspx (http://technet.microsoft.com/en-us/library/bb457096.aspx) ChangeVLKeySP1.vbs ' ' WMI Script - ChangeVLKey.vbs ' ' This script changes the product key on the computer ' '********************************************************************** ***** ON ERROR RESUME NEXT if Wscript.arguments.count<1 then Wscript.echo "Script can't run without VolumeProductKey argument" Wscript.echo "Correct usage: Cscript ChangeVLKey.vbs ABCDE-FGHIJKLMNO-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 ChangeVLKey2600.vbs ' ' WMI Script - ChangeVLKey.vbs ' ' This script changes the product key on the computer ' '********************************************************************** ***** ON ERROR RESUME NEXT if Wscript.arguments.count<1 then Wscript.echo "Script can't run without VolumeProductKey argument" Wscript.echo "Correct usage: Cscript ChangeVLKey.vbs ABCDE-FGHIJKLMNO-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 "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WPAEvents\OOBETimer" '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 The following example shows how to use the ChangeVLKeySP1.vbs script from a command line: 1. 2. Click Start, and then click Run. In the Open box, type the following command, where AB123-123AB-AB123123AB-AB123 is the new product key that you want to use, and then click OK: c:\changevlkeysp1.vbs ab123-123ab-ab123-123ab-ab123 For more information about Genuine Microsoft Software, visit the following Microsoft Web site: http://catalog.microsoft.com/genuine/purchase/UpdateInstructions.aspx (http://catalog.microsoft.com/genuine/purchase/UpdateInstructions.aspx) If you can install SP1 or a later version of Windows XP and you can restart Windows, you have resolved the issue. If the issue has not been resolved, see the "Next Steps" section. If these methods did not help you, you might want to continue to troubleshoot on your own by using the following Microsoft Web sites: Searchable Knowledge Base (http://support.microsoft.com/search/?adv=1) : Search Solution Centers (http://support.microsoft.com/select/?target=hub) : View product- Microsoft Customer Support Newsgroups technical support information and self-help tools for Microsoft products. specific frequently asked questions and support highlights. (http://www.microsoft.com/communities/newsgroups/default.mspx) : Contact counterpart s, peers, and Microsoft Most Valuable Professionals (MVPs). Other Support Options (http://support.microsoft.com/default.aspx?pr=csshome) : Use the Web to ask a question, contact Microsoft Customer Support Services, or provide feedback. If you continue to have questions after you use these Microsoft Web sites or if you cannot find a solution on the Microsoft Support Services Web site, click the following link to contact Support: http://support.microsoft.com/contactus (http://support.microsoft.com/contactus) For more information about invalid product keys, click the following article number to view the article in the Microsoft Knowledge Base: 326904 (http://support.microsoft.com/kb/326904/ ) Error message when you install Windows XP Service Pack 1 (S about invalid product keys) or Service Pack 2 (S): "The product key used to install Windows is invalid" APPLIES TO Microsoft Windows XP Professional SP2 Microsoft Windows Server 2003, Standard Edition (32-bit x86) Microsoft Windows Server 2003, Enterprise Edition (32-bit x86) Microsoft Windows Server 2003, Web Edition Microsoft Windows Server 2003, Datacenter Edition (32-bit x86) Keywords: kbsetup kbregistry kbenv kbhowto KB328874 Hai bisogno di aiuto? Contatta un tecnico Microsoft. Aiuto & Supporto ©2009 Microsoft
© Copyright 2024