all groups > dotnet distributed apps > june 2006 >
You're in the

dotnet distributed apps

group:

consuming XML web service from client side.


consuming XML web service from client side. Eli Silverman
6/19/2006 11:46:03 AM
dotnet distributed apps:
I am hoping someone can help me
I have created an xml web service and I am atempting to utilize it from the
client side.
basically what I want to do is I have a form with an input box and a select
list.
I want someone to type a couple of characters into the input box, hit enter
and have the contents of the select list re-populated with a list of people
whose last name begins with the characters entered as well as a client code
that is contained in a hidden field.
I have about 30,000 names belonging to about 200 clients and I really don't
want to have to load up an array.
The web service I created accepts the search string, client Id and the
current value of the select list and returns a string value containing the
new innerhtlm content for the select list.
I know the web service works as I can call it. pass the parameters and get
my test page.
Half the examples I see call for importing the namespace.
I have tried using WSDL as indicated in the instructions but I can not get
the import statement to see the name space.
There are a number of Java script functions on the page and a lot of other
things going on that I really don't want to have to track by doing post backs.
Can anybody help me with an example of how I can consume the output of my
web service from the client side using java script?
the web service was written in VB using VS.NET 2003 and we are using the 1.1
framework.
Thanks in advance.

Re: consuming XML web service from client side. Tasos Vogiatzoglou
6/23/2006 2:26:50 AM
For IE there is a WebService behavior that parses the SOAP and creates
a proxy for calling a w/s.

I would say that it would be better to create an asx form that acts as
a wrapper over your webservice and use XmlHTTP object with standard
HTTP methods. This will simplify things and you won't have to parse the
WSDL file.

For the latter you can check Prototype (a js library that has some
quick methods for creating crossbrowser js code)

http://prototype.conio.net/

Regards,
Tasos


[quoted text, click to view]
AddThis Social Bookmark Button