If you have a predetermined and unchanging set of possible values, you can populate a drop-down list or list box when designing the form. See To specify the list of options for a drop-down list or list box. If you have a changing set of values, you can dynamically populate a drop-down list or list box from a data source at run time. If you have a long set of values, having it stored in a data source gives the form more flexibility.For example, you can populate a drop-down list with a list of countries from a data source. Another example is to populate a list box with French product names but have English data values submitted to the data source.When you merge the data file with the form design, you would see MasterCard as one of the options in the list, but when the form gets submitted, the token MC is sent to the data source.
Tip: If you have an OLEDB data connection, you can use the Data Drop-down List object or the Data List Box object from the Custom category of the Object Library palette to populate a drop-down list or list box with data from a column in a table. See To dynamically populate a drop-down list or list box from an OLEDB data connection.
•
•
1. For example, type Credit Card.
Note: For ease of use, both the List Items active label and the Specify Item Values active label display the same Dynamic Properties dialog box.
Note: The binding you select should be a repeating data value or group so that the drop-down list or list box shows more than one item.
Note: For OLEDB data connections, the Items box is not available. Use the Item Text and Item Value boxes to select the database columns to use to populate the list.
6.
Note: If you select #data, the drop-down list shows MasterCard.
7. (Optional) To save a different value than the Item Text label to the data source, click the triangle beside the Item Value box and select a binding.
8.