<?xml-stylesheet href="xsltforms/xsltforms.xsl" type="text/xsl"?>
<?xsltforms-options debug="yes"?>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:xf="http://www.w3.org/2002/xforms" xmlns:xs="http://www.w3.org/2001/XMLSchema">
   <head>
      <title>Getting Selection List Data From the XForms Model</title>
      <xf:model>
         <xf:instance>
            <MyModel xmlns="">
               <MyCode type="xs:string" />
               <MyCodeList>
                  <Item>
                     <Label>Red</Label>
                     <Value>red</Value>
                  </Item>
                  <Item>
                     <Label>Orange</Label>
                     <Value>orange</Value>
                  </Item>
                  <Item>
                     <Label>Yellow</Label>
                     <Value>yellow</Value>
                  </Item>
                  <Item>
                     <Label>Green</Label>
                     <Value>green</Value>
                  </Item>
                  <Item>
                     <Label>Blue</Label>
                     <Value>blue</Value>
                  </Item>
               </MyCodeList>
            </MyModel>
         </xf:instance>
      </xf:model>
   </head>
   <body>
      <p>Getting Selection List Data From the XForms Model</p>
      <xf:select1 ref="/MyModel/MyCode" appearance="full" incremental="true">
         <xf:itemset nodeset="/MyModel/MyCodeList/Item">
            <xf:label ref="Label" />
            <xf:value ref="Value" />
         </xf:itemset>
      </xf:select1>
      <br />
       Output: <xf:output ref="/MyModel/MyCode" />
   </body>
</html>
