Thanks for the suggestion. I tried it and DOMPrint did not report any errors.

So, it must be something I'm doing with Xerces in my application. Something that may be suspect is that I'm caching several schemas using the loadGrammar() method. Two of the schemas have the same name, but are in different locations (e.g., a/b/c/foo.xsd and x/y/z/foo.xsd). The document that's having errors is using one of these schemas. Do the schema names need to be unique when they're cached?

Thanks,
Brian


Jesse Pelton wrote:
Have you tried the DOMPrint sample app?  It reports line and column when
it finds a problem.  You'll want to specify -n, -s, -f, and -v=always
command-line arguments, and include schemaLocation where appropriate in
the document.


-----Original Message-----
From: Brian and Victoria [mailto:b...@nc.rr.com] Sent: Sunday, February 15, 2009 5:31 PM
To: c-users@xerces.apache.org
Subject: Help with XercesDOMParser::getErrorCount()

Hello all,

Let me preface this by saying that I'm a novice with respect to XML and Xerces, but have managed reasonably well up until now.

I recently made some schema changes, and verified the changes to it and a document using it with EditiX, Exchanger XML, and Liquid XML. All the

editors report no errors with the schema or the document. However, the same document results in a non-zero error count (specifically 3 errors) when parsed and validated using Xerces (v2.8.0 under Cygwin). What's the best way to go about debugging the schema and/or document? Can I somehow get Xerces to give me a line number in the file for each error, and perhaps an error code?

Thanks,
Brian


Reply via email to