我刚刚安装了.NET Framework 4.0和C#的Visual Studio 2010,除System.Management.Instrumentation
之外,我在System.Management
命名空间下找不到任何东西。 MSDN上关于WMI的所有在线文档都告诉我必须使用System.Management.ManagementObjectSearcher
或System.Management.ManagementScope
等类,但我没有看到这些类。我的System.Management。*类在哪里?
这些类发生了什么,我该如何访问它们?
也许检查项目中的参考。它可能存在于未添加到您的项目中的项目中。 – RvdK 2010-11-16 12:05:19
你在引用System.Management.dll吗? – gcores 2010-11-16 12:05:34