Results 1 to 6 of 6

Thread: How do I send xml messages to a web server?

  1. #1
    groadsvb is offline VB.NET Forum Enthusiast
    .NET Framework
    .NET 3.5
    Join Date
    Nov 2006
    Posts
    49
    Reputation
    82

    How do I send xml messages to a web server?

    I have to post messages to a web server that will send messages back to me in response. The messages will be in xml and what I have read there may be some SOAP involved. I don't even know what to google to look for any thing. What kind of program am I writing? What techniques, methods, functions, tutorials am I looking for? Thanks from this old dog leaning new tricks.
    GAR

  2. #2
    Herman is offline VB.NET Forum Miyagee
    .NET Framework
    .NET 4.0
    Join Date
    Oct 2011
    Location
    Montreal, QC, CA
    Posts
    448
    Reputation
    346
    What does "there might be some SOAP involved" mean? If it's SOAP, then all you need is the SoapClient class. If it's something else, then you need to get clear requirements before you even start googling.

  3. #3
    JohnH's Avatar
    JohnH is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.0
    Join Date
    Dec 2005
    Location
    Norway
    Posts
    14,186
    Reputation
    2368
    If it is (like is sounds) a web service, see for example "Accessing the Service" here Walkthrough: Creating and Accessing WCF Services (enter url and Go, rather than Discover)

  4. #4
    JohnH's Avatar
    JohnH is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.0
    Join Date
    Dec 2005
    Location
    Norway
    Posts
    14,186
    Reputation
    2368
    Quote Originally Posted by Herman View Post
    If it's SOAP, then all you need is the SoapClient class.
    What you're referring to there is WSE, obsolete addon libraries of the past. The integrated 'web references' proxy in IDE earlier was a class inherited from SoapHttpClientProtocol (System.Web.Services.Protocols namespace), which is still available in VB 2010 IDE today, though well hidden.

    Since WCF arrived that is the best choice for interacting with web services, at least since 'service references' was integrated with VB 2008. WCF client proxies inherit ClientBase(Of T) class (System.ServiceModel namespace), and will also handle old SOAP services including WSE3. The generated code for proxy client for either service type is layed out pretty much the same, but the class name will differ somewhat, for example ServicenameSoapClient for a Soap service and ServicenameClient for a WCF service.

  5. #5
    Herman is offline VB.NET Forum Miyagee
    .NET Framework
    .NET 4.0
    Join Date
    Oct 2011
    Location
    Montreal, QC, CA
    Posts
    448
    Reputation
    346
    Interesting... I did know SoapClient was a little old, I did not consider it obsolete however, as we still use it for online licensing. I am somewhat reluctant (perhaps wrongly) to dive head on into new versions of old tricks if the old trick still works, usually, but I will have a look at WCF.

  6. #6
    groadsvb is offline VB.NET Forum Enthusiast
    .NET Framework
    .NET 3.5
    Join Date
    Nov 2006
    Posts
    49
    Reputation
    82
    Thanks JohnH and the rest. The walkthrough is where I will start. I will be getting specs in a couple of weeks but have hints as to what may need to be done ans since I know nothing about this kind of programming a head start will be helpful.
    GAR

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Harvest time tracking