none
Access and/or enumerate virtual folders RRS feed

  • Question

  • Greetings from Detroit!

    I am working a project where I need to be able to access a virtual drive/folder on a computer.  By virtual drive/letter, I am referring to entries like "Creative Cloud Files" , "OneDrive" or "GoogleDrive".  The obvious bit is that there is no drive letter associated with these locations and as far as I can see, they do not show up in WMI under either Win32_LogicalDrive or Win32_PNPEntity.  They do obviously show up in Explorer in the "folder list".

    Can anyone offer any pointers on how to enumerate and/or access these locations within a .Net program?

    Thanks!

    Ron Gage

    Wednesday, March 1, 2017 1:43 AM

All replies

  • Hi Ron Gage,

    >>The obvious bit is that there is no drive letter associated with these locations and as far as I can see, they do not show up in WMI under either Win32_LogicalDrive or Win32_PNPEntity.

    Yes, as you said,  Using WMI is not work for virtual folders or drive.

    So I would suggest you to map the drive or folder in local storage somewhere.

    Using the Windows API to create a drive that maps to a folder in local storage somewhere.  This does create a real drive letter. Please refer to creating virtual hard Drive  [closed]

    Hope it helps!

    Kristin


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, March 1, 2017 6:32 AM
  • Ron,

    Using virtual drive letters is from the old Dos/Novel/Unix days. It still can be used as user. 

    For programs it is about 25 years better to use UNC paths

    https://en.wikipedia.org/wiki/Path_(computing)#Uniform_Naming_Convention


    Success
    Cor

    Wednesday, March 1, 2017 9:07 AM