TextBox Group

(part of package 'Servoy Extra Components') Extends designtime/SolutionModel: JSWebComponent Extends runtime: RuntimeWebComponent

A Servoy Extra Component that groups one or more text fields, allowing for combined data input and validation.

This is a reference page; many components have detailed usage guides here.

Properties

dataProviderID

Bound data provider identifier for the text field group value. Type: Dataprovider


enabled

Flag indicating whether the text field group is enabled for user interaction. Type: Enabled Default Value: true


faclass

CSS style classes applied to the icon associated with the text field group. Type: String


format

Format string used to display and parse the text field group value. Type: Format


inputType

Specifies the type of input for the text field group (for example, "text" or "password"). Type: String Default Value: "text"


inputValidation

Specifies the validation to apply to the input (for example, "none" or "email"). Type: String Default Value: "text"


invalidEmailMessage

Message displayed when an invalid email address is entered. Type: Tagstring Default Value: "This is an invalid email address"


placeholderText

Placeholder text displayed when the text field group is empty. Type: Tagstring


readOnly

Flag indicating whether the text field group is read-only. Type: Protected Default Value: false


styleClass

CSS style classes applied to the text field group component. Type: Styleclass Default Value: "form-control"


tabSeq

Tab sequence order for keyboard navigation. Type: Tabseq


visible

Flag indicating whether the text field group is visible. Type: Visible


Events

onActionMethodID(event)

Called when the text field group triggers an action.

Parameters:

  • {JSEvent} event The event object containing details about the action event.


onDataChangeMethodID(oldValue,newValue,event)

Called when the value of the text field group changes.

Parameters:

Returns: {Boolean}


onFocusGainedMethodID(event)

Called when the text field group gains focus.

Parameters:

  • {JSEvent} event The event object containing details about the focus gained event.


onFocusLostMethodID(event)

Called when the text field group loses focus.

Parameters:

  • {JSEvent} event The event object containing details about the focus lost event.


onRightClickMethodID(event)

Called when the text field group is right-clicked.

Parameters:

  • {JSEvent} event The event object containing details about the right-click event.


API

isValid()

Checks whether the current input is a valid email address or if the input is empty.

Returns: Boolean Returns true if the input is valid (i.e., it is a valid email address or the input is empty); otherwise, false.


requestFocus(mustExecuteOnFocusGainedMethod)

Request the focus to this field.

Example:

myElement.requestFocus();

Parameters:

  • {Boolean} [mustExecuteOnFocusGainedMethod] If false will not execute the onFocusGained method; the default value is true



Last updated

Was this helpful?