Detect insertion of media into a drive using windows messages

Posted by rschnorenberg on Stack Overflow See other posts from Stack Overflow or by rschnorenberg
Published on 2010-03-10T20:01:28Z Indexed on 2010/05/30 0:02 UTC
Read the original article Hit count: 257

Filed under:
|
|
|

I am currently using WM_DEVICECHANGE to be notified when new USB drives are connected to the computer. This works great for devices like thumb-drives where as soon as the device arrives it is ready to have files read from it. For devices like SD card readers it does not because the message is sent out once when the device is connected but no message is sent when a user actually inserts a card into the device.

Is it possible to detect the insertion of new media into an existing USB device without having to use polling?

© Stack Overflow or respective owner

Related posts about c++

Related posts about win32