B4X Store

ELEVATEUI · B4A · XUI

UIMessageBox

Dialogs & notifications component. Choose it when its specific APIs suit your screen.

78 modules 1,780 APIs

Dialogs & notifications

What it solves

Dialogs & notifications component. Choose it when its specific APIs suit your screen.

Animated conceptual demonstration, not an exact Android control screenshot.

26 methods0 Designer2 events

When to use this module

When an operation needs confirmation or a result, process its response in the callback before updating the interface.

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.

Two-action confirmation
Existing documentation example dialogs-registry.json Not B4A-compiled

Review required libraries, Designer views and input data before compiling in B4A.

Sub Activity_Create(FirstTime As Boolean)
    Dim dlg As UIMessageBox
    dlg.Initialize(Activity, Me, "DeleteConfirm")
    dlg.setTitle("Eliminar registro")
    dlg.setDescription("Esta acción requiere confirmación.")
    dlg.setSubmitText("Eliminar")
    dlg.setCancelText("Cancelar")
    dlg.setBubbleDesign(True)
    dlg.Show
End Sub

Private Sub DeleteConfirm_Submit
    Log("Confirmado: ejecutar aquí el borrado de datos")
End Sub

Private Sub DeleteConfirm_Cancel
    Log("Cancelado: no se modifica ningún dato")
End Sub

Public methods reference

26 audited signatures

Public Sub Initialize(act As B4XView, Callback As Object, Eventname As String)

Prepare the instance before its other methods.

Original catalog note: Method: Initialize Description: Initializes the dialog with the parent activity, callback, and event name. Parameters: - act: The parent B4XView where the dialog will be displayed. - Callback: The object that will handle the events. - Eventname: The base name for the events.

act As B4XViewCallback As ObjectEventname As String
Public Sub setDialogBackgroundColor(NewColor As Int)

Update dialog background color at runtime when this setting changes.

Original catalog note: Sets the background color of the complete dialog surface or selection panel. Supply an ARGB color (e.g., 0xFF202536).

NewColor As Int
Public Sub setDialogBorderColor(NewColor As Int)

Update dialog border color at runtime when this setting changes.

Original catalog note: Sets the border color for the complete dialog surface. Supply an ARGB color.

NewColor As Int
Public Sub setDialogBorderWidth(Width As Float)

Update dialog border width at runtime when this setting changes.

Original catalog note: Sets the border stroke width for the complete dialog surface; zero hides the border.

Width As Float
Public Sub Show

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

Original catalog note: Method: Show Description: Displays the dialog with the configured properties.

Public Sub setTitle(title As String)

Update title at runtime when this setting changes.

Original catalog note: Set and Get methods for StrTitle

title As String
Public Sub getTitle As String

Read the current title value for validation or UI synchronization.

Returns: String

Public Sub setDescription(desc As String)

Update description at runtime when this setting changes.

Original catalog note: Set and Get methods for StrDescription

desc As String
Public Sub getDescription As String

Read the current description value for validation or UI synchronization.

Returns: String

Public Sub setImagelogo(img As Bitmap)

Update imagelogo at runtime when this setting changes.

Original catalog note: Set and Get methods for image/logo

img As Bitmap
Public Sub getLogo As Bitmap

Read the current logo value for validation or UI synchronization.

Returns: Bitmap

Public Sub setlogo2(icon As Char, IconColor As Int, Font As B4XFont)

Update logo2 at runtime when this setting changes.

Original catalog note: Set and Get methods for character-based logo

icon As CharIconColor As IntFont As B4XFont
Public Sub setAnimateImage(Animate As Boolean)

Update animate image at runtime when this setting changes.

Original catalog note: Set and Get methods for image animation

Animate As Boolean
Public Sub getAnimateImage As Boolean

Read the current animate image value for validation or UI synchronization.

Returns: Boolean

Public Sub setCornerRadius(Radius As Float)

Update corner radius at runtime when this setting changes.

Original catalog note: Set and Get methods for corner radius

Radius As Float
Public Sub setSubmitText(submitText As String)

Update submit text at runtime when this setting changes.

Original catalog note: Set and Get methods for TextSubmit

submitText As String
Public Sub getSubmitText As String

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

Returns: String

Public Sub setCancelText(cancelText As String)

Update cancel text at runtime when this setting changes.

Original catalog note: Set and Get methods for TextCancel

cancelText As String
Public Sub getCancelText As String

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

Returns: String

Public Sub setCancelButtonColor(Bcolor As Int)

Update cancel button color at runtime when this setting changes.

Original catalog note: Set and Get methods for Cancel button color

Bcolor As Int
Public Sub getCancelButtonColor As Int

Read the current cancel button color value for validation or UI synchronization.

Returns: Int

Public Sub setBubbleDesign(IsBubble As Boolean)

Update bubble design at runtime when this setting changes.

Original catalog note: Set and Get methods for bubble design

IsBubble As Boolean
Public Sub getBubbleDesign As Boolean

Read the current bubble design value for validation or UI synchronization.

Returns: Boolean

Public Sub setTop(top As Int)

Update top at runtime when this setting changes.

Original catalog note: Set and Get methods for top margin

top As Int
Public Sub setAnimationBubble(animate As Boolean)

Update animation bubble at runtime when this setting changes.

Original catalog note: Set and Get methods for bubble animation

animate As Boolean
Public Sub getAnimateBubble As Boolean

Read the current animate bubble value for validation or UI synchronization.

Returns: Boolean

Designer · 0

No custom Designer properties were found in the audited API.

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.

Submit ' Event triggered when the submit button is clicked

Raised when the user taps the control; use it to trigger a real action.

B4A handler signature with Demo prefix

Private Sub Demo_Submit ' Event triggered when the submit button is clicked()
    Log("Submit ' Event triggered when the submit button is clicked")
End Sub
Cancel ' Event triggered when the cancel button is clicked

Raised when the user taps the control; use it to trigger a real action.

B4A handler signature with Demo prefix

Private Sub Demo_Cancel ' Event triggered when the cancel button is clicked()
    Log("Cancel ' Event triggered when the cancel button is clicked")
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 Color As Int = xui.Color_RGB(30, 120, 255) ' Default dialog accent
Source: ElevateUI public API catalog; tutorials cross-checked against ElevateUI(6).b4xlib. Visualizations are illustrative; sample code requires B4A compilation.