dynamic URL for soap webservice
-
I have to call my customer's soap web service through my desktop application. For testing purpose, I created an exactly same soap web service with same asmx file name and methods with same input parameters and same return types. my application works fine with my test web service. but when i change the web service URL to customer's URL it gives me error 502 Bad gateway. When I create a new web service reference with the customer url and change all references in the source code, it works fine. but practically I can do this with test application but i can not do this with our live production application. How can I make my application to work 2 similar soap web services at 2 different URLs without getting the web reference and and recompile the application. Please suggest ...... Thank you .......
-
I have to call my customer's soap web service through my desktop application. For testing purpose, I created an exactly same soap web service with same asmx file name and methods with same input parameters and same return types. my application works fine with my test web service. but when i change the web service URL to customer's URL it gives me error 502 Bad gateway. When I create a new web service reference with the customer url and change all references in the source code, it works fine. but practically I can do this with test application but i can not do this with our live production application. How can I make my application to work 2 similar soap web services at 2 different URLs without getting the web reference and and recompile the application. Please suggest ...... Thank you .......
This is not really related to C#. You should grab the WSDL from actual serivce URL by appending
?wsdl
to it. Add that as a reference to your application code. By doing this, you get accurate service definition and a URL in app.config in your application. You can then generate a mock service using SOAP UI or any other tool of your choice and update the app.config URL to point to mock service."It is easy to decipher extraterrestrial signals after deciphering Javascript and VB6 themselves.", ISanti[^]