It's easy to package your project with the VS-pack module, and we can start the software by operating the registry when we install the deployment. The specific implementation is as follows:
1. After adding the installation deployment project, the right mouse button installation project----View--the registry, HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run add key value to save the software catalog.
Note: The default may only be hkey_current_user\software\[manufacturer], it doesn't matter, we add the above items in turn. namely: Hkey_current_user\software\[manufacturer]\windows\currentversion\run.
2, then add the environment string value in run, the key name can be the starting, value to fill the physical path of the software.
The physical path is determined by the customer in the deployment, how do we get it? Here we can use [TARGETDIR] to get the client's chosen path, plus the software's startup file name. For example, the name of the software startup file is Xx.exe, then value is: [Targetdir]xx.exe.
This way, restarting the computer system will automatically run the software we set up.
From:http://blog.sina.com.cn/s/blog_67b113a101012mac.html
"Go" C # WinForm Package deployment when adding registry information to enable boot