Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Limit access to a removeable drive programatically

Posted on 2006-06-22
8
Medium Priority
?
246 Views
Last Modified: 2011-09-20
How can I programatically limit access to a removeable drive in Windows or give access to it.  For example, I would like to password protect the drive.  If the password is supplied, let windows/current user have access to it.
0
Comment
Question by:bc4942
  • 2
  • 2
5 Comments
 
LVL 21

Expert Comment

by:alainbryden
ID: 16961879
That is something built onto a removable drive but it has nothing to do with visual basic. If you want a password protected removable drive then you need to buy a password protectable removable drive. (Most large ones come with this feature, just right click on the drive and alter it's properties)
0
 

Author Comment

by:bc4942
ID: 16962292
so there is no api call or anything with windows that would let you "disconnect" or "reconnect" a drive?  Interesting.
0
 
LVL 30

Expert Comment

by:nmcdermaid
ID: 16964939
There probably is an API but the user would actually have to run your VB App to activate it...

You could put your app in the statrup but there are many ways around that.
0
 

Author Comment

by:bc4942
ID: 16969493
I understand...Full disclosure might be needed here..  I have created a CDROM partition on a USB key (like U3)  When the Key is inserted, 2 drives are added:  a "cd-rom" and a removeable disk (just like U3).  On the CDROM there are 2 files.  My .exe and autorun.inf.  My .exe currently scans the Windows removeable drives to find the one that is the key and then executes a custom menu of items on the key (similar to U3).  Looking to limit access to that dive.
0
 
LVL 21

Accepted Solution

by:
alainbryden earned 2000 total points
ID: 16970550
Oh I see. Well then I would say the best thing to do would be to encrypt the contents of that drive and add a small decryptor to your accessing program. I know that this is the "if all else fails" solution, but it may come down to that.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question