Check Microsoft Office 2016 Product key

There are a method to check the Microsoft office 2016 product key, but the most easiest 1 is to run the script.

You can check your Microsoft Office 2016 product key using a simple VBScript. Here’s how you can do it:

Step 1: Open Notepad

  1. Press Win + R, type notepad, and press Enter.
  2. Copy and paste the following script into Notepad:


    
Dim objFSO, objShell, objKey
Dim strKeyPath, strKey
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objShell = CreateObject("WScript.Shell")

' Registry path for Office 2016
strKeyPath = "HKLM\SOFTWARE\Microsoft\Office\16.0\Registration\"

On Error Resume Next
strKey = objShell.RegRead(strKeyPath & "DigitalProductID")
If Err.Number <> 0 Then
    WScript.Echo "Could not retrieve the Office 2016 product key."
    Err.Clear
Else
    WScript.Echo "Microsoft Office 2016 Product Key: " & ConvertToKey(strKey)
End If

Function ConvertToKey(Key)
    Dim KeyChars, i, CurrentKeyPart, OutputKey, KeyOffset
    KeyChars = "BCDFGHJKMPQRTVWXY2346789"
    OutputKey = ""
    KeyOffset = 52
    For i = 24 To 0 Step -1
        CurrentKeyPart = 0
        For j = 14 To 0 Step -1
            CurrentKeyPart = CurrentKeyPart * 256 + Asc(Mid(Key, j + 1, 1))
            Mid(Key, j + 1, 1) = Chr(Int(CurrentKeyPart / 24))
            CurrentKeyPart = CurrentKeyPart Mod 24
        Next
        OutputKey = Mid(KeyChars, CurrentKeyPart + 1, 1) & OutputKey
        If (i Mod 5 = 0) And (i <> 0) Then OutputKey = "-" & OutputKey
    Next
    ConvertToKey = OutputKey
End Function



Step 2: Save the Script

  1. Click File > Save As.
  2. Change "Save as type" to All Files (*.*).
  3. Name the file Check_Office_Key.vbs (make sure the extension is .vbs).
  4. Save it on your Desktop or any preferred location.

Step 3: Run the Script

  1. Double-click the Check_Office_Key.vbs file.
  2. A window will pop up displaying your Microsoft Office 2016 product key.


Alternative: Check via Command Prompt

If you don’t want to use a script, you can check your Office product key using CMD:

  1. Press Win + R, type cmd, and press Enter.

  2. Run the following command:

        wmic path softwarelicensingservice get OA3xOriginalProductKey

If your product key is stored in the BIOS, this will retrieve it.



Important Notes:

=)



  • If Office was installed via Microsoft 365, this method won’t work.
  • If your Office key was activated via Microsoft Account, it is stored online instead of locally


  • Comments

    Popular posts from this blog

    Reading and Writing Operation of SRAM

    Reading & Writing Operation of DRAM

    Method to Convert from Stream to Json C#