Hey folks,
am having a bit of problems, prob. background info:
Okay am a Coldfusion dev. and not much into my soap. but have to use this and drive it through ASP and it won't work, so please give me a hand.
the code:
'Define Variables'
Dim objSoapClient
Dim strSoapHeader
Dim SOAPConnection
'Pre-Set all needed variables'
Set objSoapClient = Server.CreateObject("MSSOAP.SoapClient30")
SOAPConnection = "
http://127.0.0.1/script.asmx?wsdl"
'Build the SoapMessage'
strSoapHeader = strSoapHeader & "<?xml version=""1.0"" encoding=""utf-8""?>"
strSoapHeader = strSoapHeader & "<soap:Envelope xmlns:xsi=""
http://www.w3.org/2001/XMLSchema-instance"" xmlns:xsd=""
http://www.w3.org/2001/XMLSchema"" xmlns:soap=""
http://schemas.xmlsoap.org/soap/envelope/""&g...;
strSoapHeader = strSoapHeader & "<soap:Body>"
strSoapHeader = strSoapHeader & "<Authenticate xmlns=""
http://127.0.0.1/script.asmx?wsdl"">"
strSoapHeader = strSoapHeader & "<userName>UserName</userName>"
strSoapHeader = strSoapHeader & "<passWord>Password</passWord>"
strSoapHeader = strSoapHeader & "</Authenticate>"
strSoapHeader = strSoapHeader & "</soap:Body>"
strSoapHeader = strSoapHeader & "</soap:Envelope>"
'Build up the connection here'
objSoapClient.ClientProperty("ServerHTTPRequest") = True
objSoapClient.MSSOAPInit(SOAPConnection)
objSoapClient.Send strSoapHeader
bjSoapClient.SetRequestHeader "Content-Type","text/xml"
objSoapClient.SetRequestHeader "SOAPConnection", "InsertUser"
Send the POST request
receive the results
Dim strResults'
strResults = objSoapClient.ResponseTex'
Dim objXMLDoc
Set objXMLDoc = Server.CreateObject("Microsoft.XMLDOM")
objXMLDoc.LoadXML strResults
Set objSoapClient = Nothing
Response.ContentType = "text/xml"
Response.Write strResults
'clean up after yourself
Set objXMLDoc = Nothing
The Error:
Microsoft VBScript runtime error '800a01b6'
Object doesn't support this property or method: 'Send'
Now if I take out the send property... though it now rattles through the code, it doesn't actually connect to the webservice.
We never fail, we just find that the path to succes is never quite what we thought...