I think this makes sense. And i can see the problem in the way the xsd file is defined.So what you can do is
<RootElement xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="C://tmp//xml//JetPayCCSchema.xsd"> HTH, Regards, Shirish. n.b. I found a very good tutorial from Roger L. Costello at http://www.xfront.com/xml-schema.html.May be you can have a look.It has the example (no target namespace)you are looking for and many more -----Original Message----- From: O'Keeffe, Michael [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 06, 2003 11:06 PM To: '[EMAIL PROTECTED]' Subject: RE: Problem with XML Validation >From the www.w3.org site, you might creating a simple xsd, and then use the "include" element for example: <include schemaLocation="http://www.example.com/schemas/address.xsd"/> According to the site, "The one important caveat to using include is that the target namespace of the included components must be the same as the target namespace of the including schema, in this case http://www.example.com/IPO. Bringing in definitions and declarations using the include mechanism effectively adds these components to the existing target namespace. " However, the included document I am using also does not have a targetNameSpace defined, and this works. -----Original Message----- From: Vamsi Atluri [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 06, 2003 1:07 PM To: [EMAIL PROTECTED] Subject: RE: Problem with XML Validation Hi Shirsh, Thanks for the reply. But the problem is that the XSD is from an external entity and they don't have any targetNameSpace defined in their XSD file. In other words, it's not an value I can set/modify. To me, the problem looks like it's not even loading the entity resolver. I have some sysouts in my resolveEntity method in my entity resolver class, which are not being printed (it might be a dumb way to check if the method's called ...). Also, I tried the case where I do not set the entity resolver on the parser. Instead I specified the XSD file location in the XML in this form: <RootElement xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceschemaLocation=\"C://tmp//xml//JetPayCCSchema.xsd\"> Even this case gives me the same error: cvc-elt.1: Cannot find the declaration of element 'RootElement'. I am not sure what I need to do to correct this... -Vamsi --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]