OK, this is the point where I wanted you to go ;-)
Did you aply the SoapRpcService attribute to your Web Service? This enables an
RPC like WSDL whereas .NET Web Services default to a document oriented
communication style.
For more info please see:
ms-help://MS.NETFrameworkSDK/cpguidenf/html/cpconcustomizingsoapinaspnetwebserviceswebserviceclients.htm
This helps out it (nearly) all ways ...
Regards,
Christian
Catalin Tomescu wrote:
> Christian,
>
> I've tried in the first place using the autogenerated WSDL and the hight
> level API but there is an error when the WSDL file is parsed by the VB6.0
> client! So, I tried this, but as you can see without much luck.
>
> Regards,
> Catalin
>
> >From: Christian Weyer <[EMAIL PROTECTED]>
> >Reply-To: [EMAIL PROTECTED]
> >To: [EMAIL PROTECTED]
> >Subject: Re: C# Web Service and VB6.0 client
> >Date: Fri, 06 Jul 2001 23:36:14 +0200
> >
> >My question is why you are not using the high level API of STK and just
> >consuming the auto-generated .NET WSDL ?
> >Of course this does not answer your initial question ...
> >
> >Christian
> >
> >
> >Catalin Tomescu wrote:
> >
> > > Christian,
> > > I'm not using a WSDL file for the .NET service.
> > > The VB6.0 client is using the low level API and the functions are listed
> > > bellow.
> > >
> > > The .NET client is working fine, so I know for sure the .NET service is
> >also
> > > working file.
> > > But when I call the same .NET service from the VB6.0 the result is 1,
> >which
> > > means that the value for both parameters is 0. Why?
> > >
> > > VB functions:
> > > ------------
> > > Private Function Execute(ByVal Method As String, ByVal A As Double, _
> > > ByVal B As Double) As Double
> > >
> > > Dim Serializer As SoapSerializer
> > > Dim Reader As SoapReader
> > > Dim ResultElm As IXMLDOMElement
> > > Dim FaultElm As IXMLDOMElement
> > > Dim Connector As SoapConnector
> > >
> > > On Error GoTo catch_err
> > > Set Connector = New HttpConnector
> > > Connector.Property("EndPointURL") = END_POINT_URL
> > > ' Connector.Property("SoapAction") = "uri:" & Method
> > > Connector.Property("SoapAction") = CALC_NS + Method
> > > Connector.Connect
> > > Connector.BeginMessage
> > >
> > > Set Serializer = New SoapSerializer
> > > Serializer.Init Connector.InputStream
> > >
> > > Call Serializer.startEnvelope("soap")
> > > Call Serializer.startBody
> > > Call Serializer.startElement(Method, CALC_NS, , "")
> > > Call Serializer.startElement("numberOne")
> > > Serializer.writeString CStr(A)
> > > Serializer.endElement
> > > Call Serializer.startElement("numberTwo")
> > > Serializer.writeString CStr(B)
> > > Serializer.endElement
> > > Serializer.endElement
> > > Serializer.endBody
> > > Serializer.endEnvelope
> > >
> > > Connector.EndMessage
> > >
> > > Set Reader = New SoapReader
> > > Reader.Load Connector.OutputStream
> > >
> > > If Not Reader.Fault Is Nothing Then
> > > MsgBox Reader.faultstring.Text, vbExclamation
> > > Else
> > > Execute = CDbl(Reader.RPCResult.Text)
> > > End If
> > > Exit Function
> > >
> > > catch_err:
> > > Debug.Print Err.Description
> > > End Function
> > >
> > > Private Sub Command1_Click()
> > > Debug.Print Execute("addNumbers", 10, 25)
> > > End Sub
> > >
> > > .NET service code is here
> > > <%@ WebService Language="C#" Class="MyService" %>
> > >
> > > using System;
> > > using System.Web.Services;
> > >
> > > [WebService(Namespace="http://www.catalin.com/webservices/")]
> > > public class MyService: WebService {
> > > [ WebMethod(Description="return the sum of two numbers")]
> > > public double addNumbers(double numberOne, double numberTwo) {
> > > Console.WriteLine("Performing {0}+{1}", numberOne, numberTwo);
> > > return numberOne + numberTwo + 1;
> > > }
> > > }
> > >
> > > Regards,
> > > Catalin
> > >
> > > >From: Christian Weyer <[EMAIL PROTECTED]>
> > > >Reply-To: [EMAIL PROTECTED]
> > > >To: [EMAIL PROTECTED]
> > > >Subject: Re: C# Web Service and VB6.0 client
> > > >Date: Fri, 06 Jul 2001 23:07:24 +0200
> > > >
> > > >Can you please elaborate a bit more on this?
> > > >What does your WSDL look like, what does your Web Service code look
> >like
> > > >... ?
> > > >
> > > >Regards,
> > > >Christian
> > >
> > > _________________________________________________________________
> > > Get your FREE download of MSN Explorer at http://explorer.msn.com
> >
> >--
> >___________________________________________________
> >eYesoft We see your visions.
> >���������������������������������������������������
> >Christian Weyer http://www.eyesoft.de
> >
> >[EMAIL PROTECTED] Bernhard-Krieg-Str. 4
> >Tel.: +49-9393-993161 97845 Neustadt/Main
> >___________________________________________________
> > bUilding sMart iNternet aRchitectures
> >���������������������������������������������������
> >
> >
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at http://explorer.msn.com
--
___________________________________________________
eYesoft We see your visions.
���������������������������������������������������
Christian Weyer http://www.eyesoft.de
[EMAIL PROTECTED] Bernhard-Krieg-Str. 4
Tel.: +49-9393-993161 97845 Neustadt/Main
___________________________________________________
bUilding sMart iNternet aRchitectures
���������������������������������������������������