If you read Application.ExecutablePath, it gives you the disk reference for the application file that started the program. So if you program is called WhereAmI.exe and it is on a USB that appears as the "H" drive, Application.ExecutablePath will give you
You can use this to monitor for USB removal: http://www.cybersprocket.com/2011/programming-languages/detecting-usb-insertionremoval-in-c-net-4-0/
] gives the basic code. It's in C#, but it's pretty obvious.