Webservice URL

V

ViperGTS-R

Hi,

I've written a webservide which works fine. I call it from a C# class by
using a webreference. But now I want to place my webservice on another
webserver and that results in replacing the webreference and recompile the
code. My question is how I can prevent this. I used the webconfig.xml to put
in the serviceUrl but I do not manage to get it working.
In short the question is how cab I provide the URL of a webservice to a C#
application.

Thanks
Carlo
 
M

Martin Kulov

Hello ViperGTS-R,
Open properties window of your web reference proxy and select dynamic behavior. This will place an entry in your web.config file which you can modify when you change the server of your web service. Or if you want to change the location in runtime you can modify the Url property of the web service reference instance.

HTH,
Martin Kulov
www.codeattest.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,812
Latest member
GracielaWa

Latest Threads

Top