Click here to Skip to main content
15,746,066 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
See more:
how can i make the setup file to do whatever i want it to do via VB 2010 ultimate or anything else?
Let me explain.

I want the setup file when runs for first time to get the processor ID of that pc.

Then i want it to save that ID. When i run it again in a different pc i want it to get the processor ID and compare it with the one that got when it runned for first time.If its the same it will run again.If its not the same then it wont run. Thats what i want it to do .

Sorry for my english.Appreciate your help!

you can create a setup and deployment project and create a custom action which will check the processor ID at some particular place in registry or at some place in windows drive. This can be saved at both position also.

If installer find the processor ID that respective position then it can continue its installation as needed else not.

You can create custom action by checking the article Custom Action in Visual Studio setup projects[^]
Share this answer
i can get the processor ID but how can i save it so that the setup.exe file can read it next time it runs even in another pc and how can i tell the setup to stop the instalation.How can i refer to setup file with code that i have written in the custom action.Sorry for my english... Appreciate your help!.
Forgot to tell you that i use Visual Basic 2010 Ultimate...
Share this answer
Dave Kreskowiak 1-Mar-12 15:26pm    
Don't bother with the processor ID. Only Intel ever implemented it but they don't do it in the lastest generation of chips. They are abandoning the technology entirely over privacy concerns. AMD never implemented it.

Also, there is absolutely no way for an installer to know if it was already run on another PC.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900