Hello,
My problem is that I want to deploy my program onto a 'thumb drive' and sell it that way and I need the program to only run off that drive.
It is a small program that can easily be copied and run by anyone so I thought that if I could somehow 'lock' it to the small USB drive then that would solve my problem.
Because some games require a CD to be in a drive before they will run I figured that that would be something that I could do, my problem is finding any help in how that might be accomplished.
Can anyone point me in the right direction
Thank you very much
Bill Langston

Program to execute on one machine only
ReneeC
Hmm, now this is interesting. I don't want to clutter this forum up with usless posts with this one being premature but it will take me a bit of time to check this out and I wanted to let you know I got your reply.
The very idea of 'hidden files' is a little bit distasteful but the idea of someone spreading my program around without my permission is also distasteful. I've got to think this one over a bit.
Thanks nobugz, once again. Looks like I'm gonna have to put you on the payroll! (grin)
Bill Langston
eroe
Hipolito Lopez
*Scratches head* Hmmm.... seems like this should be possible some how. I know I've heard of it being done.... I would think that there should be a way to cycle through the list of available drives on the system, find the one you are running from, and determine the drive type (C - Hard Drive; D - CD-ROM; E-USB Mass Storage; etc.)
-ca
Modeller
Thank you S_DS for your reply. It is very good info for future reference but not what I was looking for. That is my mistake, I should have said 'drive' instead of 'machine'.
Specificly, I want to lock my program to a thumbdrive not a machine. I don't have a particular brand of drive chosen yet I'm still searching for the best bulk deal on them so I have to be rather 'generic' in that regard.
Thanks again for the tip, if I can't do what I want to then I will probably go with that solution but I would rather not do it that way.
Take care,
Bill Langston
windypoint
Tatworth
Perhapse.... but only one of them is going to be the one that the app is running from. Application.StartUpExecutable .... I think will give the path where the app is funning from (in .NET) .... in VB6- it's app.Path.
-ca
dmc7198
Hi,
Apparently every BIOS chip has a unique serial number or other such number.
If you can find a way to read this in then you could lock a program to one machine.
Try some of the links after clicking this one>>
http://www.google.co.uk/search hl=en&ie=ISO-8859-1&q=reading+bios+serial+number&meta=
Regards,
S_DS
enric vives
Yes, I agree -ca, I just don't have the knowledge to figure it out. I feel that if we can find a solution and have it archived here for others to see that it could be a valuable 'tool' or 'method' for programmers to have available to them. I only wish I had thought more carefully when I named this thread so people searching would find it more easily. (that is assuming we find a solution, ha, ha)
Yours truly,
Bill Langston
markovuksanovic
Thanks nobugz. I typed up a long reply and when I went to post it an error occured. Grrrr
I'll download the shareware and see what goes. Hope this goes thru!
Bill Langston
LarryETL
pkr2000
Yes, my thought was to check if the program was running from a removable device and deny if it was running from a fixed device. Like I said; just a simple thing that would stop a person from sending the program to another and them pop it onto their c: or d: drive and run it. They could copy the program to a flash drive and it would run but if I don't tell them the reason for the error then they won't know that unless they experiment. If someone is determined then there is not much I can do about that short of going crazy trying to protect this thing.
For me simple will work but for developers with much more invested a more 'robust' way to do this could be great stuff. I hope we can pursue it further.
Yours truly,
Bill langston
Gulden
kastanienreis
I think I'm getting closer. It looks like I can use the DriveInfo.GetDrives method to determine if the drive is a removable one and work with that. I am using 2.0 of the framework so this is a new method to that version.
Because I am not looking to do anything too drastic, I only want to keep honest folks honest so I think this might work for me.
Now if I can figure out how to construct things I'll be home free!
Bill Langston
P.S. "Keep it simple...", that's the ticket.
David Törnquist