1 Attachment(s)
[VB2008] USB, CDRom, Harddrive, Network drive find state & more Class!
First of all, props to this thread by obi1kenobi for getting me started on this little project.
So I had a need, a need for a class, a class that doesn't seem to exist?
So I mades one. This is by no means the "best" solution, but I can say That I've had a 98% success rate.
The only error i'm running now is if i plug and unplug and plug my black berry in real fast.
Beyond that, if you need a way to fire events for the detection of drives or cd media, and you want to grab that same drive info provided at anytime on any volume of drive, then you came to the right place (or go write your own! lol)
This class pretty much speaks for itself (alota XML doc) and use of it is even ezier! To use:
Simply import (Don't forget to add reference)
http://i669.photobucket.com/albums/v...HH/imports.png
Then reference
http://i669.photobucket.com/albums/v.../establish.png
If a usb drive is connected
http://i669.photobucket.com/albums/v.../connected.png
If a usb drive is disconnected
http://i669.photobucket.com/albums/v...HH/removed.png
Get drives connected of a certain type on
http://i669.photobucket.com/albums/v...findDrives.png
This Class also includes a simple byte converter (also get by byte value TB, GB, MG ...), a percentage grabber, & is event driven!
Re: [VB2008] USB, CDRom, Harddrive, Network drive find state & more Class!
update!
Quote:
i've spent the last few days going over windows api functions, and i can say, i will be completely rewriting this very soon with much better features and less room for error!