WMI win32_windowsproductactivation code not working

  • Thread starter Thread starter sl
  • Start date Start date
S

sl

Hi,

I m trying to run the following C# code.

ManagementClass mc = new
ManagementClass("Win32_WindowsProductActivation", new
ObjectGetOptions());

ManagementBaseObject outParams =
mc.InvokeMethod("GetInstallationID", null, null);


But it is throwing exception as "Invalid Method Parameter(s)".
Please help.
 
Hi,

I m trying to run the following C# code.

               ManagementClass mc = new
ManagementClass("Win32_WindowsProductActivation", new
ObjectGetOptions());

               ManagementBaseObject outParams =
                   mc.InvokeMethod("GetInstallationID", null, null);

But it is throwing exception as "Invalid Method Parameter(s)".
Please help.

It seems like this class is not implemented in Windows 7. Try to use
wmiexporer and browse this class. Does it work for you?
 
Back
Top