This code will allow you to change the computer description of a local or remote PC assuming you have administrator rights to it, by using WMI. The "Windows Management Instrumentation" service needs to be running for the code to function. This is the description you see if you right click on My Computer, choose "Manage", then right click on "Computer Management (Local)" and choose properties, then click on the "Network Identification" tab.

I found the core code on another site for use with VBScript and adapted it slightly to VB6. You need to include Microsoft WMI Scripting Library v1.1 or higher in your progect references.

The variable strComputer holds the network name of the PC, if you want to rename the local PC you would make it equal to "." or hard code it.

You can do this same thing on most PC's by editing the registry but I've found that some Win 2k and Win XP PC's will not update. This takes effect immediately in my testing.

VB Code:
  1. Dim strComputer as String
  2. strComputer = "."
  3. Set Obj = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2").ExecQuery("Select * FROM Win32_OperatingSystem")
  4.     For Each object In Obj
  5.         object.Description = "The Description of the Computer goes here."
  6.         object.Put_
  7.     Next