Consultor Eletrônico



Kbase 20287: XML - Error When Loading an XML File With an XSL Stylesheet
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   15/02/2005
Status: Unverified

SYMPTOM(s):

Using XSL Stylesheets.

X-NODEREF or X-DOCUMENT <method-name> got an error: <xml-exception>. (9082)

The first 2 lines in the document could be:

<?xml version="1.0" encoding="ibm850"?>
<?xml:stylesheet type="text/xsl" href="Appli.Xsl"?>

CAUSE:

This is a warning message that comes from the IBM parser. It can safely be ignored. The W3C reserves anything that begins with xml in XML.

This is done so that IBM can develop new things with names such as, for example, the xml-stylesheet Processing Instruction. IBM reports the above-mentioned warning so that developers do not create their own processing instructions with names that begin with XML.

FIX:

To work around this warning message, use the LOAD statement with the NO-ERROR option:

DEFINE VARIABLE Doc1 AS HANDLE.
CREATE X-DOCUMENT Doc1.
Doc1:LOAD("file","C:\XML\myFile.xml", FALSE) NO-ERROR.