Install Window service without visual studio command prompt without making setup

step 1> Install .net framework (I am using .net 4.0 but you can use as your requirement)

step 2> Go to run+ cmd  then click ok or directly go to your window command prompt (not visual studio command prompt )

step 3> type this lines

cd C:\Windows\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe E:\test\test\bin\Debug\test.exe

E:\test\test\bin\Debug\ is the path where my window service setup is saved

C:\Windows\Microsoft.NET\Framework\v4.0.30319\ is path where InstallUtil.exe exist.

In both InstallUtil.exe exist. and path must give a space,otherwise it raise error.

Step 4> Enjoy..your service is you can check it from control panel > administrative tool >Services.