I started playing with Windows Communication Foundation (WCF) today. I hit some pretty immediate problems that I'm still trying to work through.
I thought a good first step would be to try out a Microsoft Virtual Lab for WCF. There's one called The Fundamentals of Programming the Windows Communication Foundation that sounded just right. I went through and got to where you're supposed to have a host (console) application running that makes the service available. However, when I try to run the app, I get the following error:
Service 'DerivativesCalculatorService.DerivativesCalculatorServiceType' has zero application (non-infrastructure) endpoints. This might be because no configuration file was found for your application, or because no service element matching the service name could be found in the configuration file, or because no endpoints were defined in the service element.
There was some inconsistency in the lab manual on what namespace should be used for the projects, but I checked to make sure I had all of that lined up correctly and I did. I then tried to repeat the lab on my own machine and ended up arriving at the same problem.
I programmatically added the endpoint and removed the endpoint declaration from the app.config file, and now I get the following error:
The ChannelDispatcher at 'http://localhost:8000/Derivatives/Calculate with contract(s) '"IDerivativesCalculator"' is unable to open its IChannelListener.
The lab was created against Beta 2, at which time WCF was going to be part of .NET 2.0/WinFx, and now WCF is part of .NET 3.0. But I couldn't even get the lab to run in the virtual lab, so I'm either doing something wrong or the lab is just wrong.
Anyone have a better quickstart that they can recommend?
Update: The ChannelDispatcher error I got went away when I ran the host as an Admin. MakeMeAdmin to the rescue.