C
cmrchs
Hi,
using the Windows management Instrumentation interface (WMI) do I get illogical results :
the following works :
ManagementObject account = new ManagementObject
("Win32_logicaldisk.deviceid=\"c:\"");
account.Get();
lblName.Text = account["size"].ToString();
but the following gives me an exception
System.Management.ManagementException: Invalid object path
ManagementObject account = new ManagementObject
("Win32_Account.name=\"a_user\"");
account.Get(); // exception is thrown here
The class-name is correct though.
Any ideas ?
thanks
Chris
**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...
using the Windows management Instrumentation interface (WMI) do I get illogical results :
the following works :
ManagementObject account = new ManagementObject
("Win32_logicaldisk.deviceid=\"c:\"");
account.Get();
lblName.Text = account["size"].ToString();
but the following gives me an exception
System.Management.ManagementException: Invalid object path
ManagementObject account = new ManagementObject
("Win32_Account.name=\"a_user\"");
account.Get(); // exception is thrown here
The class-name is correct though.
Any ideas ?
thanks
Chris
**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...