Jump to content

sanket_das1

Members
  • Content Count

    6
  • Joined

  • Last visited

Everything posted by sanket_das1

  1. Hi Robot,Thanks for ur reply. I have another query .... Is there a way, so that I can convert the XSD in this format to the usual frmat and then may be parse it properly.Also if you can help me with some code snippets ...after your research it would be help full
  2. Hi Robot,I want 2 parse an XSD and not validate an XML against the XSD. I want to get to the root element of this XSD. My XSd is "Using Named Type" XSD. Please note the sample below:I have taken it from W3 forum. See thst here my application is detecting "name" as the root where as theactual root is "shiporder". I hope u got me this time. thanks.///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////<?xml version="1.0" encoding="ISO-8859-1" ?><xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"><xs
  3. Also need to know if there r any special .h(header) files that we need to include for this purpose. We have complete access to the Xersec DOM parser library files but some how we are unable to use methods like children.GetFirstXMLChild() and GetChildren() .
  4. First is we are not using an XML, but the XSD format I have posted earlier. We cannot change the XSD as it is a valid one.2ndly I am noting dowm\n some code snippet that we use for parsing schema files. Kindly go through it and post your suggestions:CString CSaTfXSrc::ParseXMLSchemaFile( const CString & sDoc ){ CString sErr; try { DOMParser parser; // Setup the rules we want the parser to use // parser.setValidationScheme(DOMParser::Val_Always); parser.setDoNamespaces(true); parser.setDoSchema(true); SchemaGrammar* grammar = (SchemaGrammar*)parser.loadGrammar(sDoc
  5. Hi all,I would also like to add the XSD sample for your refernce.PLEASE NOTE THE FIRST ELEMENT "homeOwner" in our XSD. This is being treated as root./**************************************************************************************************/<xsd:element name="homeOwner" type="xsd:boolean" minOccurs="0"/> <xsd:element name="propertyValue" type="xsd:double" minOccurs="0"> <xsd:annotation><xsd:documentation xml:lang="en"> Value of present property </xsd:documentation></xsd:annotation> </xsd:element> <xsd:element name="accTyp
  6. I have an XSD that is valid but the code in my application is unable to parse the schema as it is unable to locate the root element. We use DOM parser to validate the XSD. However it is not parsing our XSD if the first elemt is not the root elemnt.I think our problem lies in detecting the root elemt.Can you help us getting any API call or something which could help us parse the SChema. If DOM parser cannot be applicable, we can also implement the SAX parser.Please post ASAP as we have delivery deadlines.Thanks in advance
×
×
  • Create New...