标签: c# wmi wmi-query
string dirName = @"D:\Test't"; string qry = "associators of {Win32_Directory.Name='" + dirName + "'} where assocclass = Win32_SubDirectory ResultRole = PartComponent";
执行上述WMI查询时,我收到无效对象路径异常。如何在WMI查询中转义单引号?