How call a webservice from Windows VB app

jmsjms used Ask the Experts™
Hi Experts

I'm looking for an example of how to call a webservice from a VB windows application.  I'm using VB to create the application in Visual Studio 2008.   To clarify I want to get info from a webserice in a desktop application, not a aspx app.

Points awarded for example commented code and helpful comments!  Thanks!
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®


Thanks very much!


I've tried this and it doesnt work .  :-(

I've followed the link and tried it but I've not got a Internet name for the webservice, just an IP

I've referenced the webservice in the VB solution and tested it by entering the URL in Internet Explorer and this seems to work.

but then I try

    Dim mywebserviceClass As New http://an.ip.address/service1()
    mystr = mywebserviceClass.HelloWorld("fred")
    Me.TextBox1.Text = mystr

and it wont build.  I have a type http not defined...


Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial