DTD to XSD conversion

cobra11

New Member
I stuck with the following conversion from DTD:\[code\]<!ELEMENT contact (name+, ((email | phone+) | (email, phone+)), address?)>\[/code\]to XSD:\[code\]<xs:element name="contact"><xs:complexType> <xs:sequence> <xs:element maxOccurs="unbounded" ref="name"/> <xs:choice> <xs:choice> <xs:element ref="email"/> <xs:element maxOccurs="unbounded" ref="phone"/> </xs:choice> <xs:sequence><!-- Next line causes exception --> <xs:element ref="email"/> <xs:element maxOccurs="unbounded" ref="phone"/> </xs:sequence> </xs:choice> <xs:element minOccurs="0" ref="address"/> </xs:sequence></xs:complexType>\[/code\]I get 'Multiple definition of element 'email' causes the content model to become ambiguous.' exception.What I do wrong? any suggestions to overcome
 
Back
Top