|
Home > Archive > BizTalk Server General > December 2005 > How to restrict values in Schema
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
How to restrict values in Schema
|
|
|
| Hi,
In a schema, I want to have restricted values in an attribute for
example the attribute may one of two values "Valid" and "InValid"
thanks in advance
| |
| Scott Colestock 2005-12-27, 6:03 pm |
| If you don't need a reusable type, you can do something as easy as below.
(In the BizTalk editor, see the "derived by" field in the property editor,
and choose "restriction." Now visit the Enumeration property.)
Scott Colestock
www.traceofthought.net
<xs:element name="SomeElement">
<xs:complexType>
<xs:attribute name="SomeAttribute">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Valid" />
<xs:enumeration value="Invalid" />
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:complexType>
</xs:element>
"MNA" <mnadeemakhter@gmail.com> wrote in message
news:1135704974.415372.325110@g43g2000cwa.googlegroups.com...
> Hi,
> In a schema, I want to have restricted values in an attribute for
> example the attribute may one of two values "Valid" and "InValid"
>
> thanks in advance
>
| |
|
| Thanks a lot!
Scott Colestock wrote:[vbcol=seagreen]
> If you don't need a reusable type, you can do something as easy as below.
> (In the BizTalk editor, see the "derived by" field in the property editor,
> and choose "restriction." Now visit the Enumeration property.)
>
> Scott Colestock
> www.traceofthought.net
>
>
> <xs:element name="SomeElement">
> <xs:complexType>
> <xs:attribute name="SomeAttribute">
> <xs:simpleType>
> <xs:restriction base="xs:string">
> <xs:enumeration value="Valid" />
> <xs:enumeration value="Invalid" />
> </xs:restriction>
> </xs:simpleType>
> </xs:attribute>
> </xs:complexType>
> </xs:element>
>
>
>
> "MNA" <mnadeemakhter@gmail.com> wrote in message
> news:1135704974.415372.325110@g43g2000cwa.googlegroups.com...
|
|
|
|
|