Hi Vijay,

Vijay S. Bajwa <[EMAIL PROTECTED]> writes:

> I tried the followin 2 lines:
>
>  saxParser->loadGrammar ("/home/vb11258/zas/GTS-Oasys/schema/GTS-Oasys.xsd",
>               Grammar::SchemaGrammarType, true);
>  saxParser->useCachedGrammarInParse(true);


Here is the parser setup that works for me:


      SAX2XMLReader* sax (XMLReaderFactory::createXMLReader());

      sax->setFeature (XMLUni::fgSAX2CoreNameSpaces, true);
      sax->setFeature (XMLUni::fgSAX2CoreNameSpacePrefixes, true);
      sax->setFeature (XMLUni::fgXercesValidationErrorAsFatal, true);
      sax->setFeature (XMLUni::fgSAX2CoreValidation, true);
      sax->setFeature (XMLUni::fgXercesSchema, true);
      sax->setFeature (XMLUni::fgXercesSchemaFullChecking, true);

      sax->loadGrammar ("structure.xsd", Grammar::SchemaGrammarType, true);
      sax->setFeature (XMLUni::fgXercesUseCachedGrammarInParse, true);


hth,
-boris


-- 
Boris Kolpackov
Code Synthesis Tools CC
http://www.codesynthesis.com
Open-Source, Cross-Platform C++ XML Data Binding


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

Reply via email to