.net类库中,用于查询磁盘剩余空间的类是什么?
请问.net类库中,用于查询磁盘剩余空间的类是什么?除了windowsapi之外的!
------解决方案--------------------Dim FreeSpace() As UInt64 '各个逻辑盘的剩余空间
Dim MC As New ManagementClass( "Win32_LogicalDisk ")
Dim MOC As ManagementObjectCollection = MC.GetInstances
Dim MO As ManagementObject
ReDim FreeSpace(MOC.Count - 1)
i = 0
For Each MO In MOC
FreeSpace(i) = MO.Properties.Item( "FreeSpace ").Value
i += 1
Next