For serviceProcessInstaller1 open Properties tab and change 'Account' property value to 'LocalService'.
we only care about the first two characters Here's a bit of sample code from one of my services you can use as a starting point. I follow Kelsey's first set of steps to add the installer classes to my service project, but instead of creating an MSI or setup.exe installer I make the service self installing/uninstalling. Choose whichever you want to use to deploy your service. Next build your installer and it will produce an MSI and a setup.exe. By selecting the installer project as well and looking at the properties windows, you can edit the Product Name, Title, Manufacturer, etc. Change the 'Output file name:' to whatever you want. You can edit the installer output name by right clicking the Installer project in your solution and select Properties.
On the second step select "Create a Setup for a Windows Application." Visual Studio 2010 it is located in: Install Templates > Other Project Types > Setup and Deployment > Visual Studio Installer This could vary slightly for different versions of Visual Studio.ī. Right click on your solution and add a new project: Add > New Project > Setup and Deployment Projects > Setup WizardĪ. The best thing to do is use the setup wizard. You should then setup the properties as you need such as service name and user that it should run as.