Change asp.net web service address 2

I am developing an application that includes a web service at design time. I am running a service locally on my computer than publishing this service to a remote server.I want to know how can I get the web link I got and just change the address of the service to the remote server to check that everything is ok.

0


a source to share


2 answers


You can customize the service url to assign the Url property:



MyWebService.Service1 service = new MyWebService.Service1();
service.Url = NEWSERVICEURL;

      

+1


a source


Right-click the link to the web link, select Properties and select URL Management: Dynamic Properties Window. The web service URL will be automatically mapped to a config parameter in the file Web.config

, which can be easily changed without recompiling:



Screenshot http://i44.tinypic.com/ivd1rm.jpg

+1


a source







All Articles