none
can´t generate the proxy of a wcf service hosted in a windows service RRS feed

  • Question

  • Hi there:

    I´m following this article (I'm studying How to host a WCF Service in a Windows Service)

    I followed all the steps successfully, it´s a simple calculator.

    But it doesn´t show how to consume this service, it´s pretty basic so I did it.

    I created a Console App, and added a reference to the service. It's ok, the service appeared, and I added it.

    But the generated proxy has errors, whatever the text I use for the service reference namespace, say CalculatorService, when building the client project I get an error saying that "The type name 'CalculatorService' does not exist in the type 'CalculatorClient.CalculatorService.CalculatorClient'    D:\CalculatorClient\CalculatorClient\Service References\CalculatorService\Reference.cs"

    The service page shows ok:

    I uploaded the simple project, both the service and the client in SkyDrive

    What could it be?


    Believe you can do it, and you will!!

    • Edited by RalphDev Tuesday, March 25, 2014 4:19 PM
    • Changed type RalphDev Tuesday, March 25, 2014 6:21 PM
    Tuesday, March 25, 2014 3:40 PM

Answers

  • It's because your client project is called "CalculatorClient", and that is the namespace for your console project. In project settings change your default namespace to something else, and update the service reference. Then you should be good to go.
    • Marked as answer by RalphDev Tuesday, March 25, 2014 6:21 PM
    Tuesday, March 25, 2014 4:50 PM

All replies

  • It's because your client project is called "CalculatorClient", and that is the namespace for your console project. In project settings change your default namespace to something else, and update the service reference. Then you should be good to go.
    • Marked as answer by RalphDev Tuesday, March 25, 2014 6:21 PM
    Tuesday, March 25, 2014 4:50 PM
  • Thank you patawa,

    Can you please turn your response into an answer that I can mark?


    Believe you can do it, and you will!!

    Tuesday, March 25, 2014 5:51 PM
  • I'm new. How do I do that?
    Tuesday, March 25, 2014 6:17 PM
  • My bad, I don´t know why my question wasn´t really a question but a general discussion

    Believe you can do it, and you will!!

    Tuesday, March 25, 2014 6:22 PM