Get the Windows XP serial number
This example shows how to list the serial number for your installed copy of Windows XP, you need to add a textbox caled TextBox1 to a form in this example
Sub WindowsSerial()
strComputer = “.”
Set objWMIService = GetObject(”winmgmts:\\” & strComputer & “\root\cimv2″)
Set colItems = objWMIService.ExecQuery(”Select * from Win32_OperatingSystem”, , 48)
For Each objItem In colItems
Text1.Text = objItem.SerialNumber
Next
End Sub
Private Sub Form_Load()
WindowsSerial
End Sub




























