Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hello everyone. I am coming back into VB programming, after being away since VB6. Starting out with VB2008 Express Edition.

 

I am trying to write a program that will be able to detect if my smartphone is plugged into the computer. This is just the start of the application, but it is a already showing to be a difficult process.

 

Most of the information that I have found so far have been able to detect if a USB mass storage device is plugged in, by checking drive letters and such, but this won't work for the smartphone, since it isn't assigned a drive letter.

 

Thank you guys for any help you can provide.

 

FC

Posted
Hello everyone. I am coming back into VB programming, after being away since VB6. Starting out with VB2008 Express Edition.

 

I am trying to write a program that will be able to detect if my smartphone is plugged into the computer. This is just the start of the application, but it is a already showing to be a difficult process.

 

Most of the information that I have found so far have been able to detect if a USB mass storage device is plugged in, by checking drive letters and such, but this won't work for the smartphone, since it isn't assigned a drive letter.

 

Thank you guys for any help you can provide.

 

FC

 

From the experience I've had, I don't think you'll be able to accomplish this without an API.

 

Detecting USB is a low-level process and can't be accomplished with a Visual Studio language. I've done programming with USB devices in the past, but needed an API from the manufacturer (they usually make you pay for them).

 

I also wouldn't recommend basing your detection on drive letters. If you deploy this on a computer with more harddrives than the one you develop on, you will need to alter your code to reflect what's present on each computer. Then there's the added possibility that if someone has another USB device plugged in at different times, your drive letter may not always match up.

 

Sorry =\

 

~Derek

Check out my blog! DevPaper.NET

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...