开发者

Dynamic WSDL Location in .NET

开发者 https://www.devze.com 2023-01-03 02:36 出处:网络
I am building a C# application that is consuming a WSDL that is hosted by a server on our network.When I use the \"Add Web Reference\" functionality of Visual Studio, it works just fine, saving the ip

I am building a C# application that is consuming a WSDL that is hosted by a server on our network. When I use the "Add Web Reference" functionality of Visual Studio, it works just fine, saving the ip address of the machine, etc. and the SOAP calls work without any issue.

We are now making this entire application portable so that it can be installed in any environment. We would like to place all of our settings in one configuration file, so my question is开发者_JAVA技巧 this: Is it possible to somehow specify the IP address of the machine that is hosting the SOAP service in my configuration file and link everything dynamically at runtime?


You need to set Url of the service like this: Web Service URL should be a config setting --- it already is!

0

精彩评论

暂无评论...
验证码 换一张
取 消