Hi,
when validating the attached file I got the following error.
 
DOMPrint.exe -v=always -n -s -f sample.xml
Error at file "sample.xsd", line 11, column 29
   Message: A group whose content is 'all' must only appear as the content type of a complex type definition.
 
XMLSpy (for example) validates it w/o errors.
 
The question is: Whom to trust ?
 
P.S.
When changing the compositor type of the group to be a sequence, the Xerces parses it ok.
 
 
 
 
<?xml version="1.0" encoding="UTF-8"?>

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"; 
           elementFormDefault="qualified" 
           attributeFormDefault="unqualified">

	<xs:element name="A">
		<xs:complexType>
			<xs:sequence>
			    <xs:element name="B" type="xs:string"/>
			    <xs:group   ref="G"/>
   		    </xs:sequence>			
		</xs:complexType>
	</xs:element>

	<xs:group name="G">
	<xs:all> 
		<xs:element name="C" type="xs:string"/> 
		<xs:element name="D" type="xs:string"/> 
	</xs:all>
	</xs:group>

</xs:schema>
<?xml version="1.0" encoding="UTF-8"?>

<A xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
   xsi:noNamespaceSchemaLocation="sample.xsd">
   <B/>
   <C/>
   <D/>
</A>

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

Reply via email to