WinComboCtrl
Programmers are encouraged to use System.DropList instead.
(Engine-Level Function)
Description: | Windows native "combo" control. A "combo" control is an enhanced form of drop list. Displays a child window containing a Windows combo control. |
Returns: | Numeric. See comments. |
Usage: | Steady State only. |
Function Groups: | Graphics, Window |
Related to: | DropList | Edit | WinEditCtrl |
Format: | WinComboCtrl(X0, Y0, X1, Y1, Style, Data, DataTrigger, Index [, FocusID, MaxCharacters, Font, BackgroundColor, ForegroundColor]) |
Parameters: |
X0, Y0, X1, Y1 | ||||||||||||||||||||
Required. Coordinates. | ||||||||||||||||||||
Style | ||||||||||||||||||||
Required. Comprised of a combination of bit values to yield the desired effects. (See: Bitwise Parameters & Operations)
Bits 2 and 3 define input character handling. They can be set to one of the following values:
Bit 4 controls list sorting
Bits 5 through 8 are reserved. Bit 9 Specifies that the size of the combo box is exactly the size specified by the application when it created the combo box. Normally, the system sizes a combo box so that it does not display partial items.
|
Data |
Required. The one-dimensional array of data to display. |
Trigger |
Required. Can be set to non-zero to cause control data to refresh. WinComboCtrl will set this parameter back to zero after the data has been refreshed. |
Index |
Required. The current selection index in the data array. |
FocusID |
An optional parameter from 0 to 32767 indicating the focus id. If Invalid, negative, or zero, no user interaction is permitted. This value is stored in a short. |
MaxCharacters |
An optional parameter indicating the maximum number of characters permitted for input. Can not exceed 65535 or be less than 0. |
Font |
Optional Font value. Defaults to the Windows System font. Note that underlining is not supported. |
BackGroundColor |
An optional numeric parameter specifying the background color. Uses an unsigned integer, therefore system colors with negative values may not be specified here. |
ForegroundColor |
An optional numeric parameter specifying the foreground color. Like BackgroundColor, may not be negative. |
Comments: |
The return value for WinComboCtrl can be one of the following values:
0 Internal buffer changed 1 Selection made from list or Enter key pressed 2 Focus has been lost. Data must be a one-dimensional array of text values. Index is a variable that receives the current selection array index, or the text value if the droplist has an editable selection and new text is entered that does not match any item in the array. If FocusID is Invalid or less than or equal to "0", the current selection cannot be modified. |