Hi,

I have just started using Xerces. I just need some clarification on what is
happening.

I am trying to validate an XML file against an XSD. Now the XSD is
referenced in the XML as xsi:noNamespaceSchemaLocation,
and is located in the same directory as the XML.

I set to false http://apache.org/xml/features/validation/schema and
http://apache.org/xml/features/validation/schema-full-checking
as I did not want to validate the XSD, but
http://xml.org/sax/features/validation was set to true, as to validate the
XML against the XSD.

Now I receive the following error when I go to pass the XML.

Error: Document is invalid: no grammar found.
LineNumber:  4
ColumnNumber:  13
PublicID:  null
SystemID:  file:///<pathToXmlDoc>/tufes6060WebCityConfig.xml

>From what I understand this is a DTD validation error, which is answered in
the FAQ,
"How can I tell the parser to validate against XML Schema and not to report
DTD validation errors?"
Therefore I need to set http://apache.org/xml/features/validation/schema to
true to be able to parse a correct XML 
document against an XSD without getting an errors reported.
Is this correct ?
Regards

Marco Giana


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to