[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 841
  • Last Modified:

invoking webservice with only xml

I want to invoke an Axis2 Web service from .Net With only sending XML and getting result but this web service has a different end point rather then WSDL url

Thank you
0
3XLcom
Asked:
3XLcom
1 Solution
 
existenz2Commented:
In code you can overwrite the url generated from the WSDL so that it points to the correct url. Something like sample below:
No WCF:

MyWebServiceProxy proxy =new MyWebServiceProxy();
proxy.Url = ConfigurationSettings.AppSettings["webServiceUrl"];

proxy.MyMethodCall(param. etc);


WCF:
HelloWorld.HelloWorldClient client = new
WCFHelloWorldClient.HelloWorld.HelloWorldClient();

//change the endpointAddress here
client.Endpoint.Address = new
EndpointAddress("http://localhost:8899/BasicHost/HelloWorld");

Console.WriteLine(client.SayHello("steven"));

Open in new window

0

Featured Post

[Webinar] Improve your customer journey

A positive customer journey is important in attracting and retaining business. To improve this experience, you can use Google Maps APIs to increase checkout conversions, boost user engagement, and optimize order fulfillment. Learn how in this webinar presented by Dito.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now