[cisco-voip] AXL VB Examples
Granger, Simon
simon.granger at fmglobal.com
Mon Aug 4 06:39:21 EDT 2008
Hello all,
I was wondering if anyone had any VB examples of AXL coding they can
send me.
I have seen that there has been talk on the site before, but am
struggling to get anything to work..
This is what I have so far but cannot get it to work at all.
'Build the SOAP payload
xmlsoap = "<SOAP-ENV:Envelope xmlns:SOAP-ENV=" & chr(34) &
"http://schemas.xmlsoap.org/soap/envelope/" & chr(34)
xmlsoap = xmlsoap & "xmlns:xsi=" & chr(34) &
"http://www.w3.org/2001/XMLSchema-instance" & chr(34)
xmlsoap = xmlsoap & "xmlns:xsd=" & chr(34) &
"http://www.w3.org/2001/XMLSchema" & chr(34) & ">" & vbcrlf
xmlsoap = xmlsoap & "<SOAP-ENV:Body>" & vbcrlf
xmlsoap = xmlsoap & "<axl:getPhone xmlns:axl=" & chr(34) &
"http://www.cisco.com/AXL/1.0" & chr(34) & " "
xmlsoap = xmlsoap & "xsi:schemaLocation=" & chr(34) &
"http://www.cisco.com/AXL/1.0 http://10.216.4.11/schema/axlsoap.xsd" &
chr(34) & "sequence=" & chr(34) & "1234" & chr(34) & ">"
xmlsoap = xmlsoap & "<phoneName>SEP222222222245</phoneName>"
xmlsoap = xmlsoap & "</axl:getPhone>" & vbcrlf
xmlsoap = xmlsoap & "</SOAP-ENV:Body>" & vbcrlf
xmlsoap = xmlsoap & "</SOAP-ENV:Envelope>"
msgbox xmlsoap
dim xmlhttp
set xmlhttp = server.Createobject("MSXML2.ServerXMLHTTP")
'replace localhost with the server you would like to post to
const SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS = 13056
xmlhttp.setOption 2, SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS
xmlhttp.Open "POST","http://10.216.4.11:8443/axl/",false
xmlhttp.setRequestHeader "Authorization", "Basic " &
Base64Encode("CCMAdmin:ca11manager")
xmlhttp.setRequestHeader "Content-type", "text/xml"
xmlhttp.setRequestHeader "POST", "8443/axl"
xmlhttp.setRequestHeader "Content-length", len(xmlsoap) //<--
length in characters
xmlhttp.send xmlsoap
xmlhttp.responsexml.xml
Thanks
Registered No. 755780 England
Registered Office: FM Insurance Company Limited
1 Windsor Dials, Windsor,
Berkshire, UK, SL4 1RS
Regulated by the Financial Services Authority.
VAT No. G.B.: 792 4276 02
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://puck.nether.net/pipermail/cisco-voip/attachments/20080804/7501a092/attachment.html>
More information about the cisco-voip
mailing list