cancel
Showing results for 
Search instead for 
Did you mean: 

schema definitions

padmavathi
Champ in-the-making
Champ in-the-making
how to add a radio button in schema in group or choice
1 REPLY 1

arielb
Champ in-the-making
Champ in-the-making
use a schema simpleType with an enumeration restriction, for instance:

<xs:simpleType name="my_choices">
<xs:restriction base="xs:normalizedString">
<xs:enumeration value="first_choice"/>
<xs:enumeration value="second_choice"/>
<xs:enumeration value="third_choice"/>

</xs:restriction>
</xs:simpleType>

<xs:element name="my_group">
<xs:complexType>
  <xs:sequence>
   …
     <xs:element name="my_radio">
     <!– force radios by using appearance="full" –>
     <xs:annotation><xs:appinfo>
       <alf:appearance>full</alf:appearance>
     </xs:appinfo></xs:annotation>
     </xs:element>
   …
  </xs:sequence>
</xs:complexType>
</xs:element>

refer to the th forms developer guide for more information.