Solved

Sending XML via ASP page - msxml3.dll error 'c00ce56d'

Posted on 2004-08-12
3
2,398 Views
Last Modified: 2012-06-21
I get the following error when trying to send XML to a remote server

msxml3.dll error 'c00ce56d'

System error: -1072896659.

Here is the function that is causing the error

private function xmlsend(url, docSubmit)
Set poster = Server.CreateObject("MSXML2.ServerXMLHTTP")
poster.open "POST", url, false
poster.setRequestHeader "CONTENT_TYPE", "text/xml"
poster.send docSubmit
Set NewDoc = server.createobject("Microsoft.XMLDOM")
newDoc.ValidateOnParse= True
newDoc.LoadXML(poster.responseTEXT)
Set XMLSend = NewDoc
Set poster = Nothing
end function

I bulid a string line by line containing the XML info then I use the following code

Set SendDoc = server.createobject("Microsoft.XMLDOM")
SendDoc.ValidateOnParse= True
SendDoc.LoadXML(xmlString)

'Set the URL of the receiver
sURL = "https://epayhipvar.paymentech.net"

'Call the XML Send function (defined below)
set NewDoc = xmlSend (sURL, SendDoc)'xmlString)

This obviously calls the function above.

This is my first attempt at sending XML and I am not sure where to begin

0
Comment
Question by:abishome
3 Comments
 
LVL 26

Accepted Solution

by:
rdcpro earned 250 total points
ID: 11786473
Don't use "Microsoft.XMLDOM" as this points to the old 1998 parser.  Use

Set NewDoc = server.createobject("Msxml2.DomDocument")

and

Set SendDoc = server.createobject("Msxml2.DomDocument")

Also, avoid strings wherever possible, as these often introduce encoding problems.  Try to use the stream interface of the XML document object as in:

newDoc.Load(poster.responseBody)

or even simply do something like:

dim NewDoc
set NewDoc = poster.responseXML


But in your case, I think your XML string is not well formed.  Write the responseText out to the console or the web page or whatever, and examine it closely.  You can also look at the parseError object (highly recommended) to see what's up.
 
Regards,
Mike Sharp
0
 
LVL 1

Author Comment

by:abishome
ID: 11787320
It was a parser error and the clue about the parseError object helped me locate the parse error

Thanks
0
 
LVL 17

Expert Comment

by:rstaveley
ID: 13628182
At the risk of being accused of spamming your mailboxes, I'd like to piggy-back this thread to let you know that it directed me to the solution for my problem too.

In a C++ project, which uses the IDispatch just like vbscript, I'd been passing a malformed XML string to Msxml2.DOMDocument.3.0, which I passed to Msxml2.ServerXMLHTTP.3.0 to send. The send method invocation on Msxml2.ServerXMLHTTP.3.0 failed with error code 0xc00ce56d.

Your good advice directed me to check the XML for well-formedness.

Many thanks, rdcpro and abishome.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

The Confluence of Individual Knowledge and the Collective Intelligence At this writing (summer 2013) the term API (http://dictionary.reference.com/browse/API?s=t) has made its way into the popular lexicon of the English language.  A few years ago, …
Many times as a report developer I've been asked to display normalized data such as three rows with values Jack, Joe, and Bob as a single comma-separated string such as 'Jack, Joe, Bob', and vice versa.  Here's how to do it. 
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now