Link to home
Start Free TrialLog in
Avatar of GouthamAnand
GouthamAnand

asked on

how to create our own boolean type in XSD?

Hi,

One of my XML element <TaxDocumentationRequired> should have either 'Y' or 'N'.

I did as below - but still it did not work for me.
It says "Type 'http://www.w3.org/2001/XMLSchema:myBoolean' " is not declared.

<xs:element type="xs:myBoolean" name="TaxDocumentationRequired"/>

<xs:simpleType name="myBoolean">
      <xs:restriction base="xs:string">
            <xs:enumeration value="Y"/>
            <xs:enumeration value="N"/>
      </xs:restriction>
</xs:simpleType>

Can anyone help please?
ASKER CERTIFIED SOLUTION
Avatar of Gertone (Geert Bormans)
Gertone (Geert Bormans)
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of GouthamAnand
GouthamAnand

ASKER

Thanks a lot.