Windows service template missing?

Solution 1:

In Visual Studio 2015 I could not find the Windows Service template by selecting anything in left pane. Including c# -> Windows. However, when I query 'Windows Service' in the search bar at the top right corner, voilà, templates for c# or VB show up.

Solution 2:

File > New > Project > Templates > Visual C# > Windows > Classic Desktop > Windows Service

Path to windows service template

The confusion is because Microsoft's own walkthrough doesn't give the full path to the project template: https://msdn.microsoft.com/en-us/library/zt39148a(v=vs.110).aspx

Solution 3:

It it a bad documentation of Microsoft that causes confusion to many including me. Here is how: in the New Project you will need to DRILL DOWN by selecting Templates->Visual C#-> Windows Desktop (click on it!) then you will find "windows service" template on the right. see attachment.

I hope it helps.

Dunn.enter image description here

Solution 4:

For Visual Studio 2010 (10.0):

You can navigate to your Visual Studio install directory and run devenv /installvstemplates as admin

OR

You can follow the documentation on how to create a windows service without the template here

OR

You can perform the steps below to reset your Visual Studio templates:

  1. Please open Windows Explorer, and navigate to <Visual Studio Installation Path>\Common7\IDE (by default is C:\Program Files \Microsoft Visual Studio 10.0\Common7\IDE);

  2. Delete the ItemTemplatesCache, ProjectTemplatesCache folder;

  3. Open Visual Studio Command Prompt (2010) under Start menu -> All Programs -> Microsoft Visual Studio 2010 -> Visual Studio Tools (run it with Administrator privilege: right-click the program -> Run as administrator);

  4. Run the vbexpress /InstallVSTemplates switch

  5. Run the vbexpress /Setup switch

OR

you can download template here.But oroblem is it is in vb.someone can convert it to c#.