B4X Store

ELEVATEUI · B4A · XUI

UICombobox

Choose one value from a defined list inside a form or filter.

78 modules 1,780 APIs

Inputs & forms

What it solves

Choose one value from a defined list inside a form or filter.

Animated conceptual demonstration, not an exact Android control screenshot.

28 methods8 Designer2 events

When to use this module

In a data-entry form, connect the chosen value to validation and the action that submits the form.

Before integrating, examine its methods, events and Designer options.

B4A integration examples

Tutorials are based on existing project examples or audited APIs. Check each example’s prerequisites; B4A compilation is not claimed.

Practical tutorial awaiting verification

The public API, events and properties remain available. An isolated initialization is not presented as a full example; a tutorial will be added after a functional sequence is documented.

Public methods reference

28 audited signatures

Public Sub Initialize (Callback As Object, EventName As String)

Prepare the instance before its other methods.

Callback As ObjectEventName As String
Public Sub DesignerCreateView (Base As Object, Lbl As Label, Props As Map)

Invoked automatically by the B4A Visual Designer; do not call manually.

Base As ObjectLbl As LabelProps As Map
Public Sub getSelectedIndex As Int

Read the current selected index value for validation or UI synchronization.

Original catalog note: Gets/sets the selected index.

Returns: Int

Public Sub setSelectedIndex(i As Int)

Update selected index at runtime when this setting changes.

i As Int
Public Sub getSelectedText As Object

Read the current selected text value for validation or UI synchronization.

Original catalog note: Gets the text of the selected index.

Returns: Object

Public Sub getSelectedValue As Object

Read the current selected value value for validation or UI synchronization.

Original catalog note: Gets the value of the selected index.

Returns: Object

Public Sub SetItems(Texts As List)

Use SetItems for its named operation; follow its exact signature.

Original catalog note: Sets the texts of all items.

Texts As List
Public Sub SetItems2(Texts As List, Values As List)

Use SetItems2 for its named operation; follow its exact signature.

Original catalog note: Sets the texts and values of all items.

Texts As ListValues As List
Public Sub SetItems3(Data As Map)

Use SetItems3 for its named operation; follow its exact signature.

Original catalog note: Sets texts and values of all items getting them from the Data map passed. Data keys must be strings.

Data As Map
Public Sub addItemsFromSQLite(DB As SQL, TableName As String, DisplayFieldName As String, MaxTextLength As Int, ValueFieldName As String, ValueFieldType As String)

Use addItemsFromSQLite for its named operation; follow its exact signature.

Original catalog note: Sets the texts and values of all items getting them from an SQLite table. ValueFieldType: pass one of LMCB_FIELD_TYPE_ constants provided by this class. Example: <code> SetItemsFromSQLite(SQL1, "Person", "LastName", 15, "ID", LMCB_FIELD_TYPE_INT) </code>

DB As SQLTableName As StringDisplayFieldName As StringMaxTextLength As IntValueFieldName As StringValueFieldType As String
Public Sub addItemsFromSQLiteSorted(DB As SQL, TableName As String, DisplayFieldName As String, MaxTextLength As Int, ValueFieldName As String, ValueFieldType As String, Ascending As Boolean, CaseSensitive As Boolean)

Use addItemsFromSQLiteSorted for its named operation; follow its exact signature.

Original catalog note: Same as SetItemsFromSQLite plus the ability to sort values.

DB As SQLTableName As StringDisplayFieldName As StringMaxTextLength As IntValueFieldName As StringValueFieldType As StringAscending As BooleanCaseSensitive As Boolean
Public Sub SetValue(Index As Int, Value As Object)

Use SetValue for its named operation; follow its exact signature.

Original catalog note: Sets the value of the item at the specified index.

Index As IntValue As Object
Public Sub AddItem(Text As String)

Use AddItem for its named operation; follow its exact signature.

Original catalog note: Adds a text item (its related value is automatically set to Null)

Text As String
Public Sub AddItem2(Text As String, Value As Object)

Use AddItem2 for its named operation; follow its exact signature.

Original catalog note: Adds an item, its text and its related value.

Text As StringValue As Object
Public Sub InsertItemAt(Index As Int, Text As String)

Use InsertItemAt for its named operation; follow its exact signature.

Original catalog note: Insert a new text item at the specified Index position (its related value is automatically set to Null).

Index As IntText As String
Public Sub InsertItemAt2(Index As Int, Text As String, Value As Object)

Use InsertItemAt2 for its named operation; follow its exact signature.

Original catalog note: Insert a new text and value item at the specified Index position.

Index As IntText As StringValue As Object
Public Sub GetItems As List

Use GetItems for its named operation; follow its exact signature.

Original catalog note: Returns the texts of items as list.

Returns: List

Public Sub GetValues As List

Use GetValues for its named operation; follow its exact signature.

Original catalog note: Returns the values of all items as list.

Returns: List

Public Sub RemoveItemByIndex(Index As Int)

Use RemoveItemByIndex for its named operation; follow its exact signature.

Original catalog note: Removes the item at specified index.

Index As Int
Public Sub RemoveItemByText(Text As String)

Use RemoveItemByText for its named operation; follow its exact signature.

Original catalog note: Remove the item whose text is as specified.

Text As String
Public Sub RemoveItemByValue(Value As Object)

Use RemoveItemByValue for its named operation; follow its exact signature.

Original catalog note: Remove the item whose value is as specified.

Value As Object
Public Sub GetItemValue(Index As Int) As Object

Use GetItemValue for its named operation; follow its exact signature.

Original catalog note: Returns the value at the specified index.

Index As Int

Returns: Object

Public Sub GetItemText(Index As Int) As String

Use GetItemText for its named operation; follow its exact signature.

Original catalog note: Returns the text at the specified index.

Index As Int

Returns: String

public Sub CustomCombobox( colorBackground As Int,Dropdown_BackgroundColor As Int,Arrow_Color As Int,Text_Color As Int)

Public API declaration; refer to the library behavior for usage details.

Original catalog note: Verified against supplied 2026-11-28 .b4xlib

colorBackground As IntDropdown_BackgroundColor As IntArrow_Color As IntText_Color As Int
Public Sub setCornerRadius(Radius As Int)

Update corner radius at runtime when this setting changes.

Original catalog note: Métodos para cambiar radio, borde y color del borde en tiempo de ejecución

Radius As Int
Public Sub setBorderWidth(Width As Int)

Update border width at runtime when this setting changes.

Width As Int
Public Sub setBorderColor(Color As Int)

Update border color at runtime when this setting changes.

Color As Int
Public Sub setColorBackground(Color As Int)

Update color background at runtime when this setting changes.

Color As Int

Designer · 8

#DesignerProperty: Key: BackgroundColor, DisplayName: Background Color, FieldType: Color, DefaultValue: #FF6F7583, Description: Set the background color.#DesignerProperty: Key: DropdownBackgroundColor, DisplayName: Dropdown Background Color, FieldType: Color, DefaultValue: #FF6F7583, Description: Set the background color of the dropdown menu.#DesignerProperty: Key: BorderColor, DisplayName: Border Color, FieldType: Color, DefaultValue:#FAE8ECED, Description: Set the border color.#DesignerProperty: Key: ArrowColor, DisplayName: Arrow Color, FieldType: Color, DefaultValue: #FF0A0303, Description: Set the color of the arrow.#DesignerProperty: Key: CornerRadius, DisplayName: Corner Radius, FieldType: Int, DefaultValue: 15, MinRange: 0, Description: Set the corner radius of the border.#DesignerProperty: Key: BorderWidth, DisplayName: Border Width, FieldType: Int, DefaultValue: 0, MinRange: 0, Description: Set the border width.#DesignerProperty: Key: TextColor, DisplayName: Text Color, FieldType: Color, DefaultValue: #FF1B202D, Description: Set the text color.#DesignerProperty: Key: TextSize, DisplayName: Text Size, FieldType: Int, DefaultValue: 14, MinRange: 1, Description: Set the text size.

Public events and how to implement them · 2

Initialize with Me and the event prefix Demo, then add the following handler to your B4A module. Names and arguments come from the library declaration.

SelectedChanged (Index As Int)

Raised when a selection or value changes; use it to update dependent data.

B4A handler signature with Demo prefix

Private Sub Demo_SelectedChanged(Index As Int)
    Log("SelectedChanged")
End Sub
SelectedChanged2 (Text As String, Value as Object)

Raised when a selection or value changes; use it to update dependent data.

B4A handler signature with Demo prefix

Private Sub Demo_SelectedChanged2(Text As String, Value as Object)
    Log("SelectedChanged2")
End Sub

For code-created controls use Initialize(Me, "Demo") when that signature exists; for Designer controls set the event name there. Replace Demo with the actual prefix.

Public fields, constants and types

Public mBase As B4XViewPublic cmbBox As ComboBoxPublic cmbBox As SpinnerPublic mBtn As B4XViewPublic DelayBeforeChangeEvent As IntPublic Tag As ObjectPublic B4iCancelButton As String = "Cancel"Public Const LMCB_FIELD_TYPE_INT As String = "Int"Public Const LMCB_FIELD_TYPE_TEXT As String = "String"
Source: ElevateUI public API catalog; tutorials cross-checked against ElevateUI(6).b4xlib. Visualizations are illustrative; sample code requires B4A compilation.