I thought this looked too simple...

Oct 12, 2011 at 4:24 AM


I'm new to WCF (and fairly new to Visual Studio) but have managed to created a server-side application that serves up a WSDL file.  However, my already-existing SOAP client doesn't seem to accept the WSDL file -- I think it's because the WSDL file has xsd:import statements, i.e. it's not flat.

So, I came across the WCFExtras part of CodePlex and, based on the "Using the code" section, I said "Great, I only have to add 13 lines of code to my app.config file and I'm done".  When I downloaded WCFExtras, it exploded into a complete Visual Studio solution with dozens of files!  My question is: What do I do with these files???  The "Using the code" section of CodePlex only says to add 13 lines to my app.config file.  Somehow, I don't think adding these 13 lines will do anything by itself.

I have my own Visual Studio project, of course, so it appears I have to somehow merge some number of files from CodePlex with my own files.  No clue how to do this.

Can someone provide the step-by-step process how to integrate the WCFExtra files into my own project (presuming that's what I should do)?  I *think* I'll need a fair amount of detail.  If the answer comes back as a one sentence generalization, for example, I don't think that will help.

Of course, if the merge *is* a complex process, the process would ideally be added to the WCFExtras documentation to benefit others.

Again, all I care about is flattening the WSDL file.  Thanks for any help anyone can provide!


Mar 7, 2013 at 3:03 PM
Edited Mar 7, 2013 at 3:03 PM
I know this is an old question, but thought I'd answer it for the benefit of anyone else looking. Here are my notes from just getting it working:
  1. Download WCFExtras from: http://wcfextras.codeplex.com/ and unpack the zip somewhere
  2. Reference the supplied bin/WCFExtras.dll from your project by right clicking References, clicking Add Reference and navigating to where you unzipped to.
  3. Follow the instructions for how to setup you web.config here: http://wcfextras.codeplex.com/wikipage?title=HowToUse&referringTitle=Home
    1. Note the comments at the bottom for gotchas
    2. Check the provided SampleServer\Web.Config for more hints as to where the individual bits go
  4. Add [XmlComments] above the main [ServiceContract] in your code where the /// <Summary> etc entries are.
    1. E.g. put it in the Interface declaration of your service if you have one
  5. Go to your project's properties screen, go to the Build tab, and tick the "XML documentation file" option, keeping the default value
  6. Build and publish your project
  7. Navigate to your ?wsdl url and check your code comments are there in the <wsdl:documentation> tags
  8. Also, you can check the code comments in the View | Object Browser window in Visual Studio and navigate to your service's interface.
Hope that helps.