DlgComboBox.GetProperties

table DlgComboBox.GetProperties ( 

number ControlID )

Description

Gets the properties of a combo box control on the current screen.

Note: This action will only work if called from a screen's events and if the named control is on the current screen.

Parameters

ControlID

(number) The numeric ID of the combo box control whose properties you want.

Returns

(table) A table containing the control properties, indexed by the following categories:

KEY

TYPE

DESCRIPTION

Enabled

boolean

Whether or not the control is enabled. If true is returned the control is enabled. A false result means it is disabled. You can access this value using tb.Enabled.

ItemCount

number

The number of items currently in the combo box. You can access this value using tb.ItemCount.

Selected

number

The one based index of the currently selected item.  If nothing is selected, -1 is returned. It can be access using tb.Selected.

Sorted

boolean

Whether or not the combo box is sorted. If true is returned, it is sorted and a false result means it is not sorted. You can access this value using tb.Sorted.

Text

string

The text currently displayed in the control. It can be accessed using tb.Text.

Visible

boolean

Whether or not the control is visible. If true is returned the control is visible. A false result means it is not visible. You can access this value using tb.Visible.

If the current screen does not contain the control, this action will fail. If this action fails, nil is returned. You can use Application.GetLastError to determine whether this action failed, and why.

ResultVariable

When adding an action with the action editor, you can use this field to specify a variable that the return value will be stored in.

See also:  Related Actions