Click here to Skip to main content
15,885,546 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
How can I remove/eject any usb device programmatically e.g usb storage, usb network dongle, smart phone in c++ win32? I am able to read all PnP devices and their attributes. Now using their hardware id, I want to remove/eject selected devices. Any suggestion and code snippets will be welcomed. Thanks in advance
Posted

1 solution

There is an article on CP you might want to read: How to Prepare a USB Drive for Safe Removal[^]

Microsoft also has article on it: How To Ejecting Removable Media in Windows[^]

Hope they help.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900