简体   繁体   中英

How do I create a installation package in visual studio 2010 after installed it is automatically run when boot?

I have .net windows application project, I can able to create installation package and installation has been done successfully. After installed my project, it has been run successfully when i click manually. I need to run my project automatically when my system boot.

How to create installer after install my project,it has to run automatically whenever my system boot. Teach me how to done this work.

You can either add an registry key to HKEY_LOCAL_MACHINE\\Software\\Microsoft\\Windows\\CurrentVersion\\Run which contains the path to your executable, or you can add a shortcut in the directory Startup in the user's start menu. I'd recommend the registry key, as the user won't see more of your program's shortcuts but the functionality is thesame.

Another way to approach this is to let the user decide what to do. You could create some sort of configuration screen, which lets the user decide if your software should run at boot. Essentially, you could do thesame thing I described above, but handle it in your code rather than in your installer. Depending on what software you built, this way you don't push the user to have your software started at boot.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM