none
DriveInfo and Win32_DiskPartition partition mapping RRS feed

  • Question

  • Hello I'm using DriveInfo and Win32_DiskPartition to get partitions of each physical disk drives, but question is can I trust windows partition mapping that Disk #0 Partition #0 always be C:/ and so on?
    Thursday, June 21, 2018 7:27 AM

All replies

  • No. The Disk/partition information is the physical drive information (controller, port). This has nothing to do with the logical structure of the drives. 

    Unfortunately getting this information via WMI is difficult. Way back in 2005 the Scripting Guys put together this script but even then they warned that it didn't make a lot of sense.


    Michael Taylor http://www.michaeltaylorp3.net

    Thursday, June 21, 2018 2:09 PM
    Moderator