TComboBox
From OpenEUO
A TComboBox component is an edit box with a scrollable drop-down list attached to it. Users can select an item from the list or type directly into the edit box.
- TComboBox.AutoCloseUp
- TComboBox.AutoComplete
- TComboBox.AutoDropDown
- TComboBox.BevelEdges
- TComboBox.BevelInner
- TComboBox.BevelKind
- TComboBox.BevelOuter
- TComboBox.Clear
- TComboBox.ClearSelection
- TComboBox.DropDownCount
- TComboBox.DroppedDown
- TComboBox.ItemIndex
- TComboBox.Items
- TComboBox.MaxLength
- TComboBox.OnChange
- TComboBox.OnSelect
- TComboBox.SelLength
- TComboBox.SelStart
- TComboBox.SelText
- TComboBox.SelectAll
- TComboBox.Sorted
- TComboBox.Style
- TComboBox.Text
Inherited from TWinControl:
- TWinControl.CanFocus
- TWinControl.Focused
- TWinControl.Handle
- TWinControl.OnEnter
- TWinControl.OnExit
- TWinControl.SetFocus
- TWinControl.TabOrder
- TWinControl.TabStop
Inherited from TControl:
- TControl.Align
- TControl.Anchors
- TControl.BringToFront
- TControl.ClientHeight
- TControl.ClientToScreen
- TControl.ClientWidth
- TControl.Color
- TControl.Constraints
- TControl.Cursor
- TControl.Enabled
- TControl.Font
- TControl.Height
- TControl.Hide
- TControl.Hint
- TControl.Left
- TControl.OnClick
- TControl.OnDblClick
- TControl.Parent
- TControl.PopupMenu
- TControl.ScreenToClient
- TControl.SendToBack
- TControl.Show
- TControl.ShowHint
- TControl.Top
- TControl.Visible
- TControl.Width
Inherited from TComponent:
Inherited from TObject:
Example:
cbox = Obj.Create('TComboBox') cbox.Parent = form -- set to containing object's name cbox.Top = 25 cbox.Left = 25 cbox.Width = 180 cbox.Items.Add('a line in the combo box') -- add more lines cbox.ItemIndex = 0 -- the first item is selected
cbox.OnChange = function(pSender) --[[ event fires immediately after the user edits the text in the edit region or selects an item from the list. The Text property gives the new value in the edit region. --]] end
cbox.OnSelect = function(pSender) --[[ event fires when user changes the selected item in the drop-down list. OnSelect occurs after the selection has changed and the Text property reflects the new item. --]] end