Visual Basic.NET
  Home arrow Visual Basic.NET arrow Page 3 - Calling a Web Service using VB6 with SOAP ...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
VISUAL BASIC.NET

Calling a Web Service using VB6 with SOAP 3.0
By: Jayaram Krishnaswamy
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 61
    2006-04-12

    Table of Contents:
  • Calling a Web Service using VB6 with SOAP 3.0
  • The web services used in the tutorial
  • Example 2: Calling a ColdFusion web service
  • Example 3: SOAP client calling the Enc/Denc web service

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Calling a Web Service using VB6 with SOAP 3.0 - Example 2: Calling a ColdFusion web service


    (Page 3 of 4 )

    In this example the same web service is called, but with the New construct. In order to use SOAP 3.0 with this method, you should access the Microsoft SOAP Type Library 3.0, which adds the MSSOAP30.dll (the version used in this tutorial is 3.0.1325.0) . You can access this by going to Project-->References from the main menu. If you do not see this, then you will have to download it from the Microsoft website. It is also installed with Office 2003 (Office 11). Sometimes you may have to browse if it is located in another path with the Browse...button.

    With the type library added you can access the various objects, methods and events in the object browser as shown. It has many classes as shown here, of which the class of interest at present is the SoapClient30.

     If you forgot to add this reference and tried to run the code, you would get a compiler error message as follows:

    To form1 of a new project, add a button and a text box after adding the reference. Now review the code for calling the service shown below, added to the click event.

    Private Sub Command1_Click()
    Dim clnt As New SoapClient30
    Dim strsvc As String
    clnt.MSSoapInit "http://localhost/CF_WebSvc/justFunction.cfc?wsdl"
    strsvc = clnt.WelcomeMsg(Text1.Text)
    MsgBox (strsvc)
    End Sub

    Because you have established a reference you get the advantage of intellisense, and as you type in the code you get the cue to the appropriate property, method, or event to choose. Now if you execute the above code, you get the same kind of reply as before, since nothing else has changed.

    More Visual Basic.NET Articles
    More By Jayaram Krishnaswamy


       · Web services in one form or another is here to stay. A number of easy to understand...
       · The article is good to begin with. Is SOAP a generic solution for communicating...
       · What kind of difficulty did you experience. Lots of time it is to do with the data...
       · It is possible to call a web service method using VB6 with SOAP 3.0.It is ok if...
       · Could you be little more specific? I am not sure what exactly you are trying to...
       · Hi, I am facing problem to "Calling Web Services in VB6"If any one already...
       · Could be more specific as to what kind of a problem?
       · code that can call web service
       · Your answer is very brief and I cannot fathom the exact problem you are having.The...
       · Does the client server need the MS SOAP Toolkit installing before you can use SOAP...
       · I have followed exaactly the same from the tutorial but it prompt an error. The...
       · Well, now i roughly know what caused this to happen. It only happen when i am using...
       · Hi,is it possible to pass some credential information like user name and...
       · Hi Jay,Im getting the follwoing error when trying to use VB 6.0 to access a...
       · If you receive this error message try the suggestion below:Connector:Connection...
       · how to call a web service created using vb.net.how to use the vb6 application to...
       · Hi,You asked me to put clnt.ClientProperty("ServerHTTPRequest") = True before...
       · I written following code(in vb 6.0) to call webservice (.net 2.0)Dim strparam ...
       · Your code really helped me a lot. Thanks mate. Thanks a lot.
     

    VISUAL BASIC.NET ARTICLES

    - User-defined Functions using Visual Basic Ap...
    - Understanding Object Binding in VBA
    - Mastering the Message Box
    - Testing a Windows Forms Application
    - Using Visual Basic.NET Features to Code a Wi...
    - Correcting Code in a Windows Forms Applicati...
    - Write Readable Code and Comments for Windows...
    - How to Code and Test a Windows Forms Applica...
    - Adding Features to a Windows Forms Applicati...
    - How to Design a Windows Forms Application
    - LINQ to XML Programming Using Visual Basic.N...
    - Understanding Delegates using Visual Basic.N...
    - Create a Sudoku Puzzle Generator using VB.NET
    - Entity Creation and Messaging in a VB.NET Te...
    - Movement and Player Statistics in a VB.NET T...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    Stay green...Green IT