Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I create a WCF Service Library project in Visual Studio 2017?

I need to develop an application for my distributed computing class, with one central server and multiple graphical clients. I was thinking of trying WCF for this, since I am already familiar with making .NET standalone desktop applications using Windows Forms or WPF.

Since I have never worked with WCF before, I am trying to follow a tutorial posted on MSDN, which has defining a service contract as its first major step.* Part of this involves creating a WCF Service Library project, which is supposed to be available as a template under the language of my choice (I am going to use C# here). However, I do not see this project template listed as an option in the new project dialog, and looking for WCF in the search bar returns no results.

How can I make this project template available for use in Visual Studio 2017?

* It should probably be noted that the tutorial mentions that it is written with Visual Studio 2012 in mind. Has anything changed since then that I should be aware of as far as the tutorial is concerned?

like image 642
Knowledge Cube Avatar asked May 01 '17 02:05

Knowledge Cube


2 Answers

Open the installer, choose Individual Components and scroll down to Development Activities. Check the WCF checkbox:

WCF checkbox in the Visual Studio installer

like image 197
Nick Westgate Avatar answered Sep 23 '22 20:09

Nick Westgate


I ended up re-running the Visual Studio Installer to modify my current setup. WCF is not explicitly listed anywhere, but I figured it might have been included as part of the .NET Core or ASP.NET workloads (which were not marked for installation the first time around). After adding these workloads to my installation and restarting Visual Studio 2017, I can now see the WCF project templates listed under C#.

like image 45
Knowledge Cube Avatar answered Sep 23 '22 20:09

Knowledge Cube