Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

invoking webservice with only xml

Posted on 2010-09-18
1
Medium Priority
?
837 Views
Last Modified: 2013-11-19
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
Comment
Question by:3XLcom
1 Comment
 
LVL 14

Accepted Solution

by:
existenz2 earned 2000 total points
ID: 33714195
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

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

JavaScript has plenty of pieces of code people often just copy/paste from somewhere but never quite fully understand. Self-Executing functions are just one good example that I'll try to demystify here.
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that undeā€¦
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question