Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

List Physical Drives (c++ | WINAPI)

1,755 views
Skip to first unread message

CAHEK

unread,
Apr 2, 2008, 4:05:15 AM4/2/08
to
Hello!
I want to list all physical drives on my machine...
anybody knows how to do this?


(win32 api, c++)

Kellie Fitton

unread,
Apr 2, 2008, 10:33:40 AM4/2/08
to


Hi,

You can use the following APIs to get the currently available disk
drives on your machine:

GetLogicalDrives()

GetLogicalDriveStrings()

GetDriveType()

http://msdn2.microsoft.com/en-us/library/aa364972.aspx

http://msdn2.microsoft.com/en-us/library/aa364975.aspx

http://msdn2.microsoft.com/en-us/library/aa364939.aspx

Kellie.

Ben Voigt [C++ MVP]

unread,
Apr 7, 2008, 1:08:39 PM4/7/08
to

You're looking for the list that shows up in Device Manager, right?

SetupDi* will do that, perhaps SetupDiCreateDeviceInfoList is what you are
looking for


CAHEK

unread,
Apr 8, 2008, 4:36:55 AM4/8/08
to
Hi!
Could u explain me how can i filter medias for display
just hard drives? I can't find any exemple and i never uded
SedupDi functions...
0 new messages