B4X Store

ELEVATEUI · B4A · XUI

UITabGroup

Group related content and control tab selection.

78 modules 1,780 APIs

Navigation & onboarding

What it solves

Group related content and control tab selection.

Animated conceptual demonstration, not an exact Android control screenshot.

10 methods0 Designer1 events

When to use this module

In a multi-screen application, connect every menu action to a real destination and preserve the active selection.

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

10 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 CreateTabGroup(Parent As B4XView, Left As Int, Top As Int, Width As Int, Height As Int)

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

Parent As B4XViewLeft As IntTop As IntWidth As IntHeight As Int
Public Sub AddTab(TabName As String, ContentPanel As B4XView)

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

Original catalog note: Adds a standard text tab

TabName As StringContentPanel As B4XView
Public Sub AddTabWithIcon(TabName As String, ContentPanel As B4XView, IconChar As String, IconFont As B4XFont, IconColor As Int)

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

Original catalog note: Adds a tab with a font icon (e.g. FontAwesome / Material Icons)

TabName As StringContentPanel As B4XViewIconChar As StringIconFont As B4XFontIconColor As Int
Public Sub AddTabWithImage(TabName As String, ContentPanel As B4XView, Image As B4XBitmap)

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

Original catalog note: Adds a tab with a bitmap image

TabName As StringContentPanel As B4XViewImage As B4XBitmap
Public Sub AddTabWithImageFile(TabName As String, ContentPanel As B4XView, Dir As String, FileName As String)

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

Original catalog note: Adds a tab with an image file from assets or dir

TabName As StringContentPanel As B4XViewDir As StringFileName As String
Public Sub SelectTab(Index As Int)

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

Index As Int
Public Sub GetTabTitle(Index As Int) As String

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

Index As Int

Returns: String

Public Sub getCurrentIndex As Int

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

Returns: Int

Public Sub ClearTabs

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

Designer · 0

No custom Designer properties were found in the audited API.

Public events and how to implement them · 1

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.

TabChanged(TabIndex As Int, TabName As String)

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

B4A handler signature with Demo prefix

Private Sub Demo_TabChanged(TabIndex As Int, TabName As String)
    Log("TabChanged")
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 TabWidth As Int = 100dipPublic ActiveColor As Int = 0xFFFDE047 ' YellowPublic InactiveColor As Int = 0xFF94A3B8 ' Slate 400Public ActiveIconColor As Int = 0xFFFDE047Public InactiveIconColor As Int = 0xFF94A3B8Public IndicatorHeight As Int = 3dipPublic TabHeight As Int = 44dipPublic TextSize As Float = 14Public IconSize As Float = 18Public IconPosition As String = "LEFT" ' "LEFT" o "TOP"Public TextFont As B4XFont
Source: ElevateUI public API catalog; tutorials cross-checked against ElevateUI(6).b4xlib. Visualizations are illustrative; sample code requires B4A compilation.