Hola, escribo para consultar lo siguiente: estoy utilizando el objeto
Msxml2.ServerXMLHTTP para pasar un xml a otra pagina y esta me retorna una
respuesta que debo mostrar en pantalla. Para hacer esto me base en un ejemplo
del msdn respecto a este objeto. Pero al ejecutar la página, me aparece el
mensaje :
"El documento XML debe tener un elemento de nivel superior. Error al
procesar el recurso
http://tupungato/RE/SContent/Prueba...ueba1.asp. "
No entiendo a que se pueda deber este error. El código que utilizo es:
<%@language=JScript%>
<%
var objSrvHTTP;
var objXMLDocument;
objSrvHTTP = Server.CreateObject ("Msxml2.ServerXMLHTTP");
objXMLDocument = Server.CreateObject ("Msxml2.DOMDocument");
xml =
"<rendicionLinea><cabeceraMensaje><folioMensaje>000000000460020</folioMensaje><tipoMensaje>M7</tipoMensaje><versionMensaje>3</versionMensaje><origenMensaje>PAGOENLINEA</origenMensaje><destinoMensaje>790000000001</destinoMensaje><fechaMensaje>29/07/2004
00:00</fechaMensaje><refAddress>037</refAddress><estadoMensaje>OK</estadoMensaje></cabeceraMensaje><detallePagos><idCarro>1569</idCarro><detalleProductos><productos><IndicePago>1</IndicePago><idConvenio>77911640-9</idConvenio><numeroProducto>1</numeroProducto><numeroCliente>77911640-9</numeroCliente><montoProducto>98247</montoProducto><estadoTrx><estadoTransaccion>001</estadoTransaccion><fechaTransaccion>29/07/2004
04:28:38</fechaTransaccion></estadoTrx></productos></detalleProductos></detallePagos></rendicionLinea>";
objXMLDocument.async= false;
objXMLDocument.loadXML(xml);
//objSrvHTTP.open
("POST","
http://tupungato/RE/SContent/Prueba...uot;,false);
objSrvHTTP.open
("POST","
http://tupungato/RE/SContent/Prueba...uot;,false);
objSrvHTTP.send (objXMLDocument);
Response.ContentType = "text/xml";
Response.Write (objSrvHTTP.responseXML.xml);
%>
...Bueno eso no más. agradecido de cualquier ayuda que me puedan dar
IPA
Leer las respuestas