A combo box is similar to a drop-down list, except that it accepts text entered from the keyboard and has additional options.
You initialize a combo box in exactly the same way as a drop-down list. If the user enters text into the combo box, it fills the 0th element of the array. In other respects, you treat a combo box as an enterable area that uses its array or a choice list as the set of default values.
On Data Change event to manage entries into the enterable area, as you would for any enterable area object. For more information, refer to the description of the Form event code command in the 4D Language Reference manual.
Options for combo boxes
Combo box type objects accept two specific options concerning choice lists associated with them:
- Automatic insertion: enables automatically adding a value to a list stored in memory when a user enters a value that is not found in the choice list associated with the combo box.
- Excluded List (list of excluded values): allows setting a list whose values cannot be entered in the combo box. If an excluded value is entered, it is not accepted and an error message is displayed.
Alpha Format - Bold - Bottom - Choice List - Class - Date Format - Font - Font Color - Font Size - Height - Help Tip - Horizontal Sizing - Italic - Left - Object Name - Right) - Time Format - Top - Type - Underline - Variable or Expression - Vertical Sizing - Visibility - Width