Advanced Record List - Combo Box Control Syntax

Syntax

[%K= Table,{ Keylist_Expression } [ { Filter_Expression } ] % [. Width [, Height ]] Variable_Name [ ! rl_* ][ ? Enabled ] ]

Arguments

Table

Character. The name of the table supplying the data to be displayed.

Keylist_Expression

Character. Defines the order of the data in the record list and the columns in the record list. Uses a special function called KEYLIST_BUILD().

Filter_Expression

Character. Optional. Default = all records. Filters the data that is shown in the Keylist_Expression.

Width

Numeric. The width of the control.

Height

Numeric. The height of the control.

Variable_Name

Character. The name of a character variable to receive the user selection, or a numeric variable to receive the index value of the selected radio button. The index of the top-most button is 1.

rl_*

Character. Optional. See Event Syntax.

Enabled

Logical. Optional. See Enabled Syntax.

Description

The Record List - Combo Box Control provides a dynamic view of selected records and fields from a table or set.

You must not have any space characters in the finished command.

 Example

For example, the following script creates a combo box 30 characters wide:

ui_dlg_box("Print Mail Label",<<%dlg%
Preview mail labels for which customer?;
[%k=clients,{keylist_build('1:25,2:25,3:25', customer_id, alltrim(firstname) + ' ' + lastname, phone, city)}%.30key];
{lf};
<Preview!ok> <Cancel>
%dlg%,<<%code%
if a_dlg_button = "ok" then
    filter_expression = "customer_id = '" + key + "'"
    label.Preview("mail_labels", filter_expression)
end if
%code%)

See Also