Overthere
asked on
ASP AND XML
I have a block of coding that is killing me. I am sending an XML document to a website. From the error message I receive, it is because my xml is not well-formed when validated at w3. I can not spot the coding error. And what really gets me is that in line 1 there isn't a character at position 152 ? I have displayed the offending line, all of the coding and a snapshot of what I receive using IE Developers tool.
I have coded it exactly as specified from the receiving site documentation.
It appears the xml version is not formed correctly - I don't know what it is...any help appreciated. I have messed with this for hours - LOL
I have coded it exactly as specified from the receiving site documentation.
It appears the xml version is not formed correctly - I don't know what it is...any help appreciated. I have messed with this for hours - LOL
<?xml version=" & vdblqoutes & "1.0" & vdblqoutes & " encoding=" & vdblqoutes & "utf-8" & vdblqoutes & "?>"
And the entire coding:vdblqoutes = chr(34)
'// URL to which to send XML data
url = "http://ws.mysite.com/test/myGateway.asmx"
xmlmsg = ""
xmlmsg = "<?xml version=" & vdblqoutes & "1.0" & vdblqoutes & " encoding=" & vdblqoutes & "utf-8" & vdblqoutes & "?>" & VbCrLf_
xmlmsg = xmlmsg & "<soap:Envelope xmlns:xsi=" & vdblqoutes & "http://www.w3.org/2001/XMLSchema-instance" & vdblqoutes & " xmlns:xsd=" & vdblqoutes & "http://www.w3.org/2001/XMLSchema" & vdblqoutes & VbCrLf_
xmlmsg = xmlmsg & "<soap:Header>" & VbCrLf_
xmlmsg = xmlmsg & "<GatewaySoapAuthentication xmlns=" & vdblqoutes & "http://ws.mysite.com/" & vdblqoutes & ">" & VbCrLf_
xmlmsg = xmlmsg & "<Username>MARTHA</Username>" & VbCrLf_
xmlmsg = xmlmsg & "<Password>DOGS</Password>" & VbCrLf_
xmlmsg = xmlmsg & "</GatewaySoapAuthentication>" & VbCrLf_
xmlmsg = xmlmsg & "</soap:Header>" & VbCrLf_
xmlmsg = xmlmsg & "<soap:Body>" & VbCrLf_
xmlmsg = xmlmsg & "<GetBookingDetails xmlns=" & vdblqoutes & "http://ws.mysite.com/" & vdblqoutes & ">" & VbCrLf_
xmlmsg = xmlmsg & "<BookingDetailsRequest>" & VbCrLf_
xmlmsg = xmlmsg & "<BookingNumber>2134</BookingNumber>" & VbCrLf_
xmlmsg = xmlmsg & "</BookingDetailsRequest>" & VbCrLf_
xmlmsg = xmlmsg & "</GetBookingDetails>" & VbCrLf_
xmlmsg = xmlmsg & "</soap:Body>" & VbCrLf_
xmlmsg = xmlmsg & "</soap:Envelope>"
XML-ERROR.JPG
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER