ComboBox

Top  Previous  Next

ComboBox is a Process Field and it should be placed into a ProcessRecord Element.

  <tr mo:type="ProcessRecord"> 
    <td>
      <select name="pf_CATEGORY" onchange="PMgr.fieldChanged(this)"
          mo:name="CATEGORY" mo:type="ComboBox" mo:field="true" 
          mo:needsInit="true" mo:iValue="{CATEGORY}"
          mo:props="nonBlank:true, valHandler:MyValHandler, valErrorHandler:MyErrorHandler">
        <option value="1">CAT1</option>
        <option value="2">CAT2</option>
        ...
      </select>
     </td>
  </tr>

The options of the ComboBox can be defined dynamically using XSL code as follows. Note that mo:needsInit attribute is required to set the initially selected value of the ComboBox.

  <select name="pf_CATEGORY" onchange="PMgr.fieldChanged(this);" 
    mo:type="ComboBox" mo:field="true" mo:name="CATEGORY" mo:needInit="true" 
    mo:iValue="{CATEGORY}">
    <xsl:for-each select="/root/categories/item">
      <option value="{ID}"></xsl:value-of select="NAME"/></option>
    </xsl:for-each>
  </select>

See ComboBox function class in  MoreMotion Face API.

See Validation Properties