我使用以下脚本:
get-wmiobject -class win32_physicalmemory | select Name, Model, Speed, Capacity, DeviceLocator输出列出了4块内存,但我想做的是计算物理内存和的数量,然后列出模型、速度、容量和设备定位器。
我试过使用:
(get-wmiobject -class win32_physicalmemory | select Name, Model, Speed, Capacity, DeviceLocator).count但这只是返回4,而不是4和附加属性。
发布于 2013-12-09 14:28:27
您可以将此分为两部分:
$mem = get-wmiobject -class win32_physicalmemory | select Name, Model, Speed, Capacity, DeviceLocator
"Count is $($mem.count)"
$memhttps://stackoverflow.com/questions/20472749
复制相似问题