V
Vesna Sarajevo
Hi all and thanx for your help in advance.
I'm using MS SOAP Toolkit V3 to call my webservice (which works) but I
always get 0 in result, whatever numbers
I send. This is just a dummy function that adds two numbers. Do you
know what I'm doing wrong?
This is the code:
----------------------------------------------------------------------------------------------------------------------------------------------------------
Dim Serializer As SoapSerializer30
Dim Reader As SoapReader30
Dim Connector As SoapConnector30
Set Connector = New HttpConnector30
Connector.Property("EndPointURL") = txtURL.Text
Connector.Property("SoapAction") = "http://tempuri.org/VesnaTest/
VesnaTest/AddMe"
Connector.Connect
Connector.BeginMessage
Set Serializer = New SoapSerializer30
Serializer.Init Connector.InputStream
'Serializer.StartEnvelope "soap"
Serializer.StartEnvelope
Serializer.StartBody
Serializer.StartElement "AddMe"
Serializer.StartElement "a"
Serializer.WriteString CInt(txtX)
Serializer.EndElement
Serializer.StartElement "b"
Serializer.WriteString CInt(txtY)
Serializer.EndElement
Serializer.EndElement
Serializer.EndBody
Serializer.EndEnvelope
Connector.EndMessage
Set Reader = New SoapReader30
Reader.Load Connector.OutputStream
If Not Reader.Fault Is Nothing Then
lblResult.Caption = Reader.FaultString.Text
Else
lblResult.Caption = Reader.RpcResult.Text
End If
------------------------------------------------------------------------------------------------------------------
I'm using MS SOAP Toolkit V3 to call my webservice (which works) but I
always get 0 in result, whatever numbers
I send. This is just a dummy function that adds two numbers. Do you
know what I'm doing wrong?
This is the code:
----------------------------------------------------------------------------------------------------------------------------------------------------------
Dim Serializer As SoapSerializer30
Dim Reader As SoapReader30
Dim Connector As SoapConnector30
Set Connector = New HttpConnector30
Connector.Property("EndPointURL") = txtURL.Text
Connector.Property("SoapAction") = "http://tempuri.org/VesnaTest/
VesnaTest/AddMe"
Connector.Connect
Connector.BeginMessage
Set Serializer = New SoapSerializer30
Serializer.Init Connector.InputStream
'Serializer.StartEnvelope "soap"
Serializer.StartEnvelope
Serializer.StartBody
Serializer.StartElement "AddMe"
Serializer.StartElement "a"
Serializer.WriteString CInt(txtX)
Serializer.EndElement
Serializer.StartElement "b"
Serializer.WriteString CInt(txtY)
Serializer.EndElement
Serializer.EndElement
Serializer.EndBody
Serializer.EndEnvelope
Connector.EndMessage
Set Reader = New SoapReader30
Reader.Load Connector.OutputStream
If Not Reader.Fault Is Nothing Then
lblResult.Caption = Reader.FaultString.Text
Else
lblResult.Caption = Reader.RpcResult.Text
End If
------------------------------------------------------------------------------------------------------------------