Hi Bram, I'm not sure why you're trying to break this up into parts, but seems that you really do need both XSDs in order to validate your document. Try specifying both of them using the property.
Thanks. Michael Glavassevich XML Parser Development IBM Toronto Lab E-mail: mrgla...@ca.ibm.com E-mail: mrgla...@apache.org Bram Vandeputte <bram.vandepu...@cs.kuleuven.be> wrote on 04/29/2009 03:02:15 AM: > Hello again, > > This is a follow-up message from my previous "external XML schema > validation" mail ;-) > > So I need to validate an xml with nodes with two different > namespaces, som of them have "http://ltsc.ieee.org/xsd/LOM" as a > namespace, and other have "http://www.mace-project.eu/xsd/LOM". > So I want first to validate against the xsd of the first namespace, > and in a second round validate against the xsd of the second > namespace. The problem is that when I only provide the xsd of one > namespace (through xmlReader.setProperty("http://apache. > org/xml/properties/schema/external-schemaLocation","http://ltsc. > ieee.org/xsd/LOM http://ltsc.ieee.org/xsd/lomv1.0/lomLoose.xsd");), > I get an error saying it doesn't find a declaration for the other namespace : > Error at Line 2: cvc-elt.1: Cannot find the declaration of element > 'mace:learningObjectKind'. > This is why I was experimenting with all the property and feature > options of xerces2, and probably why I messed up the URI of the > external-schemaLocation :-) > > If you could help me out, that would be fantastic, I already lost a > lot of time experimenting with this :-( > > greetings, > Bram > > -- > Bram Vandeputte > > Katholieke Universiteit Leuven > Dept. Computer Science > Celestijnenlaan 200A, A03.010 > B-3001 Leuven, Belgium > > Phone: +32 16 327659 > Mob: +32 474 667796 > Fax: -