Visual Studio Development Bookmark and Share   
 index > Visual Studio Guidance Automation Toolkit > Add WCF Service Reference
 

Add WCF Service Reference

HI,

I am creating a guidance package with multiple actions for VS2008. There are quite a few projects, one of them is WCF service. My requirement is to create all the projects in one recipe and then add the service reference to client project (win project). I've created all the proejcts in one go and have code to add wcf reference to client dynamically but everytime I try to run this package, I get following error when it goes to discover the URI (even if I try accessing this service in IE while package is running, it shows same error)

System.Net.WebException was caught
Message="There was an error downloading 'http://localhost:1245/DESServices/AuthorizationService.svc'."
Source="System.Web.Services"
StackTrace:
at System.Web.Services.Discovery.DiscoveryClientProtocol.Download(String& url, String& contentType)
at System.Web.Services.Discovery.DiscoveryClientProtocol.DiscoverAny(String url)
at NorthernTrust.EnterpriseTemplate.Helper.DteHelperCustom.DiscoverMetadata(Uri address) in C:\Work\HDG 3.0\NEL\Dev\Upgrade2008\NorthernTrust.EnterpriseTemplate\NorthernTrust.EnterpriseTemplate\Helper\DteHelperCustom.cs:line 540
InnerException: System.Net.WebException
Message="The request failed with HTTP status 404: Not Found."
InnerException:

Once package is run fully, I can access service in web browser. Can anyone explain whats going wrong and what should I do?

Thanks.
Azeem Fraz  Monday, April 21, 2008 10:09 PM
Hi,

This doesn't look like a GAX issue.

By the exception you posted it looks like you're trying to hit this URL:

http://localhost:1245/DESServices/AuthorizationService.svc'

Which clearly shows a 404, not found error... the web server is running locally on your computer (thus the 'localhost') and your URL contains the hardcoded '1245' port number. The VS's built-in WebServer usually randomizes this port number, so this may be the cause of the error you're getting...

-Victor.
vga  Friday, April 25, 2008 5:37 AM
Hi,

This doesn't look like a GAX issue.

By the exception you posted it looks like you're trying to hit this URL:

http://localhost:1245/DESServices/AuthorizationService.svc'

Which clearly shows a 404, not found error... the web server is running locally on your computer (thus the 'localhost') and your URL contains the hardcoded '1245' port number. The VS's built-in WebServer usually randomizes this port number, so this may be the cause of the error you're getting...

-Victor.
vga  Friday, April 25, 2008 5:37 AM

You can use google to search for other answers

Custom Search

More Threads

• GAT and DSL
• Problem adding reference to CSharp projects
• Web Service Software Factory - Data Types from XSD
• Add as Link and name space
• Upgrading Headaches
• The following arguments are required and don't have values
• Help me decide: how to generate my Data Access Layer ( please :)
• Can instal GAT (and MobileClient! ;( )
• Help needed in creating an installer for the guidance package which I've created
• Failed to load value providers