And I had to make sure that the url in the ServiceReference.ClientConfig file and the configuration for the web service match the url for the web service *.svc file on the web server. I found this to be a problem when it came comes to trying to run the projects from inside Visual Studio 2010, I have to switch the url to match the local server. I also found out that I had to change the code for calling the web service.
Uri address = new Uri(Application.Current.Host.Source, "../YourService.svc"); // this url will work both in dev and after deploy.You can read the links I used to come up with this:
var webService = new YourWebService.YourWebServiceClient("YourServiceEndPointName", address.AbsolutePath);
Deployment of Silverlight App + Silverlight-Enabled WCF Service to Production
Deploying Silverlight with WCF Services
No comments:
Post a Comment