- From: Edwin Dankert <edankert@cladonia.com>
- Date: Thu, 23 Oct 2003 16:22:34 +0100
- To: xmlschema-dev@w3.org
I would suggest first changing your XMLSchema, to make sure not all 'your' elements are in the XMLSchema namespace, like below: <?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:element name="A"> <xs:complexType> <xs:all> <xs:element ref="B"/> </xs:all> <xs:attribute ref="TestAtt"/> </xs:complexType> </xs:element> <xs:element name="B"> <xs:complexType> <xs:attribute ref="TestAtt"/> </xs:complexType> </xs:element> <xs:attribute name="TestAtt" use="required"> <xs:simpleType> <xs:restriction base="positiveInteger"> <xs:enumeration value="1"/> <xs:enumeration value="2"/> </xs:restriction> </xs:simpleType> </xs:attribute> </xs:schema> Validating the above schema with the Exchanger XML Editor (using Xerces 2.5.0) gives the following errors: ERROR on line 17, column 46 s4s-att-not-allowed: Attribute 'use' cannot appear in element 'attribute'. ERROR on line 19, column 43 src-resolve: Cannot resolve the name 'positiveInteger' to a(n) 'type definition' component. ERROR on line 19, column 43 cos-applicable-facets: Facet 'enumeration' is not allowed by type null. Hope this was helpful? Regards, Edwin Dankert Cladonia Ltd. http://www.cladonia.com/ "Svend Bent Nielsen" wrote in message news:BAY7-F28FZ0stgr3SU000036532@hotmail.com... Hello all, Using http://www.w3.org/2001/03/webdata/xsv for checking my schemas, I get the following error "Invalid per cvc-complex-type.1.3: undeclared attribute {None}:use" with a link to the (I think) relevant part of the documentation. Problem is that I don't understand it at all - I have absolutely no idea whatsoever as to what it means. I give an example (which gives one error) below. Can anyone tell me what is wrong? If it is solvable, I will be happy for the right syntax too. Sincerely, Svend Bent Nielsen <?xml version="1.0"?> <schema xmlns="http://www.w3.org/2001/XMLSchema"> <element name="A"> <complexType> <all> <element ref="B"/> </all> <attribute ref="TestAtt"/> </complexType> </element> <element name="B"> <complexType> <attribute ref="TestAtt"/> </complexType> </element> <attribute name="TestAtt" use="required"> <simpleType> <restriction base="positiveInteger"> <enumeration value="1"/> <enumeration value="2"/> </restriction> </simpleType> </attribute> </schema> _________________________________________________________________ Få alle de nye og sjove ikoner med MSN Messenger http://messenger.msn.dk/
Received on Thursday, 23 October 2003 11:23:43 UTC