Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries >Thread Prev - Error when creating a restriction? [Thread Next] RE: Error when creating a restriction?To: NULL Date: 6/1/2006 11:00:00 AM "Thomas Malia" wrote: > I'm trying to create a type by creating a restiction on another type. > > I'm starting off by just copying the entire content of the base type > directly into the <xs:restriction> element of the derived type... XMLSpy">XMLSpy > says my derived type is not a valid restiction of the base type.... How the > heck can that be if it's an exact copy of the base type? What am I doing > wrong? > > I don't think you want to start off copying the entire content of the base type into the <xs:restriction> element. Rather just set the base="yourType" and the content that goes inside the <xs:restriction> element is the restrictions you're putting in place, such as enumerations, for example: <xs:restriction base="myType"> <xs:enumeration value="val1"/> <xs:enumeration value="val2"/> </xs:restriction> | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
