1

I have hosted two WCF services using a console application, one on port 8080 and the other at port 8090. I am able to create object for the first service named AccountManagementService but not for the other service named UserRegistrationService.

Snapshot below shows that two services have been added. enter image description here

The second service doesn't show up in intellisense at all.

The complete details of the service used can be found at the following link(this is also a question asked by me): Hosting two WCF services using a single console app

I have tried multiple times deleting and creating new service but nothing seems to be working. Please suggest.

Community
  • 1
  • 1
AnkitMittal
  • 166
  • 2
  • 18

2 Answers2

2

based on the image, it should be there. open the reference.cs file for the service that is not showing up in IntelliSense and check the namespace. Then Try creating the reference using the full name. to get to the reference.cs file, click on Show all files in solution explorer as shown below

enter image description here

for example, if in reference.cs, you see the namespace WWWCF.UserRegistration as foo.bar.WWWCF.UserRegistration, then create instance using

foo.bar.WWWCF.UserRegistration ref = new foo.bar.WWWCF.UserRegistration ();
Dhawalk
  • 1,257
  • 13
  • 28
  • Interesting. The reference.cs for the first service has entries in it, while the one for the second service is empty. Am I mistaking something ? – AnkitMittal Apr 10 '14 at 19:51
  • if reference.cs is empty, there might be issues with the service? can you reach to WSDL for the second service? – Dhawalk Apr 10 '14 at 19:52
  • Yes. I can see the WSDL doc. – AnkitMittal Apr 10 '14 at 19:54
  • when you try and do, as service reference for the second service, does it show anything in services and operation panes? – Dhawalk Apr 10 '14 at 19:56
  • I have found the solution. Thanks for your time. The Reference.cs file was the best lead which guided me towards the solution. I really appreciate. – AnkitMittal Apr 10 '14 at 21:02
0

Found the solution. Not sure I understand the reason, though. But the following link has answers to my issue and has solved it.

Empty Reference.cs file issue solved

Community
  • 1
  • 1
AnkitMittal
  • 166
  • 2
  • 18