Hey All,
Below is a sample of the code that I was handed in VB using the SOAP SDK
--I did not write this -- don't shoot the messenger ;-)
Private Const ENC = "http://schemas.xmlsoap.org/soap/encoding/"
Private Const XSI = "http://www.w3.org/1999/XMLSchema-instance"
Private Const XSD = "http://www.w3.org/1999/XMLSchema"
Set Connector = New HttpConnector
Set Serializer = New SoapSerializer
Set Reader = New SoapReader
URI = "urn:" & "soap"
Connector.Property("EndPointURL") = "http://www.soaptest.com/soap.php"
Connector.Connect
Connector.Property("SoapAction") = URI & "#" & method
Connector.BeginMessage
Serializer.Init Connector.InputStream
Serializer.startEnvelope , ENC
Serializer.SoapNamespace "xsi", XSI
Serializer.SoapNamespace "SOAP-ENC", ENC
Serializer.SoapNamespace "xsd", XSD
Serializer.startBody
Serializer.startElement "trackmail", URI, , "method"
Serializer.startElement "subject"
Serializer.SoapAttribute "type", , "xsd:string", "xsi"
Serializer.writeString msgsubject
Serializer.endElement
Serializer.startElement "text"
Serializer.SoapAttribute "type", , "xsd:string", "xsi"
Serializer.writeString msgtext
Serializer.endElement
Serializer.endElement
Serializer.endBody
Serializer.endEnvelope
Connector.EndMessage
'have the reader parse the response
Reader.Load Connector.OutputStream
If Reader.RPCResult.nodeTypedValue = "Succeeded" Then
MsgBox "Success"
Else
MsgBox "Failed"
End If
I am looking to port these SOAP calls to C# using the new WSE. I assume
that I will need to make use of the new SoapWebRequest and such. However,
when I search the samples, none of them use SoapWebRequest.
Can anyone advise based upon the sample provided?
Thanks & Regards,
TC