I have created a Windows Service in visual studios 2015, and want to use a virtual machine running windows 10 to test it. However, I am having trouble installing the service. I have enabled share file and shared the file containing my service executable, but when I try to use the command line to install it, it doesn't seem to work. I can't use the visual studios developer command prompt since it is not installed on my VM. Anyone know a way to do this?
You can do it without visual studio developer command prompt.
Technically those are the steps:
cd C:\Users\XXX\YYY\bin\Release
install the service using that command (check your .net framework version in the VM): C:\Windows\Microsoft.NET\Framework\v4.0.30319\installutil yourservicename.exe
probably you will need give permissions to the release (or whatever folder you have).
the permissions is for LOCAL SERVICE
and NETWORK SERVICE
groups:
right click on the release folder>>properties>>security tab>>Edit button >>Add button >>search for LOCAL SERVICE and NETWORK SERVICE using the Check Names button and finally allow those groups full control Permission.