B4A Library [B4X] [XUI] AS TextFieldAdvanced - Title, Information, Counter, Password, Button, Prefix, Suffix, Icons, Multiline

With this view you can quickly and easily add good looking text fields, with title and or bottom text. Additionally you can make the TextField a button, so that you can open menus, but still keep the design of the text fields.
The view speeds up development because you don't have to worry about almost anything, it looks nice by default and is functional.

I spend a lot of time in creating views, like this and to create a high quality view cost a lot of time. If you want to support me and further views, then you can do it here by Paypal or with a coffee. :)

In B4J the view does not work properly yet, I am working on fixing the bugs. B4J works now
(21) mage.png


Password strength indicator V1.20+
AS_TextFieldAdvancedStrengthIndicator.gif


Required Fields V1.21+
AS_TextFieldAdvanced Required Fields.gif


Underline Style
AS_TextFieldAdvanced Underline.gif


ComboBox
AS_TextfieldAdvancedComboBoxExample.gif

ASTextFieldAdvanced
Author: Alexander Stolte
Version: 1.23

  • ASTextFieldAdvanced_Counter
    • Fields:
      • CounterMax As Int
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • TextColor As Int
      • View As ASTextFieldAdvanced_ViewCounter
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_Hint
    • Fields:
      • FocusedTextColor As Int
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • NonFocusedTextColor As Int
      • Text As String
      • View As ASTextFieldAdvanced_ViewHint
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_Information
    • Fields:
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • Text As String
      • TextColor As Int
      • View As ASTextFieldAdvanced_ViewInformation
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_LeadingIcon
    • Fields:
      • Icon As B4XBitmap
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • View As ASTextFieldAdvanced_ViewLeadingIcon
      • Visible As Boolean
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_Prefix
    • Fields:
      • Gap As Float
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • Text As String
      • TextColor As Int
      • View As ASTextFieldAdvanced_ViewPrefixSuffix
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_Suffix
    • Fields:
      • Gap As Float
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • Text As String
      • TextColor As Int
      • View As ASTextFieldAdvanced_ViewPrefixSuffix
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_Title
    • Fields:
      • FocusedTextColor As Int
      • Height As Float
      • IgnoreProperties As Boolean
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • NonFocusedTextColor As Int
      • Text As String
      • TextColor As Int
      • View As ASTextFieldAdvanced_ViewTitle
      • Visible As Boolean
      • xFont As B4XFont
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_TrailingIcon
    • Fields:
      • Icon As B4XBitmap
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • View As ASTextFieldAdvanced_ViewTrailingIcon
      • Visible As Boolean
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewCounter
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xlbl_Counter As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewHint
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xlbl_Hint As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewInformation
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xlbl_Information As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewLeadingIcon
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xiv_Icon As B4XView
      • xpnl_Background As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewPrefixSuffix
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xlbl_PrefixSuffix As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewTitle
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xlbl_Title As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • ASTextFieldAdvanced_ViewTrailingIcon
    • Fields:
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • xiv_Icon As B4XView
      • xpnl_Background As B4XView
    • Functions:
      • Initialize
        Initializes the fields to their default value.
  • AS_TextFieldAdvanced
    • Events:
      • ButtonClick
      • ClearButtonClick
      • EnterPressed
      • FocusChanged (HasFocus As Boolean)
      • LeadingIconClick
      • PasswordRevealChanged (Revealed As Boolean)
      • TextChanged (Text As String)
      • TrailingIconClick
    • Fields:
      • mBase As B4XView
      • Tag As Object
    • Functions:
      • Class_Globals As String
      • CreateASTextFieldAdvanced_Counter (Visible As Boolean, CounterMax As Int, IgnoreProperties As Boolean, xFont As B4XFont, TextColor As Int, View As ASTextFieldAdvanced_ViewCounter) As ASTextFieldAdvanced_Counter
      • CreateASTextFieldAdvanced_Hint (Visible As Boolean, Text As String, IgnoreProperties As Boolean, FocusedTextColor As Int, NonFocusedTextColor As Int, xFont As B4XFont, View As ASTextFieldAdvanced_ViewHint) As ASTextFieldAdvanced_Hint
      • CreateASTextFieldAdvanced_Information (Visible As Boolean, Text As String, IgnoreProperties As Boolean, xFont As B4XFont, TextColor As Int, View As ASTextFieldAdvanced_ViewInformation) As ASTextFieldAdvanced_Information
      • CreateASTextFieldAdvanced_LeadingIcon (Visible As Boolean, Icon As B4XBitmap, View As ASTextFieldAdvanced_ViewLeadingIcon) As ASTextFieldAdvanced_LeadingIcon
      • CreateASTextFieldAdvanced_Prefix (Visible As Boolean, Text As String, IgnoreProperties As Boolean, xFont As B4XFont, TextColor As Int, Gap As Float, View As ASTextFieldAdvanced_ViewPrefixSuffix) As ASTextFieldAdvanced_Prefix
      • CreateASTextFieldAdvanced_Suffix (Visible As Boolean, Text As String, IgnoreProperties As Boolean, xFont As B4XFont, TextColor As Int, Gap As Float, View As ASTextFieldAdvanced_ViewPrefixSuffix) As ASTextFieldAdvanced_Suffix
      • CreateASTextFieldAdvanced_Title (Visible As Boolean, Text As String, Height As Float, IgnoreProperties As Boolean, xFont As B4XFont, FocusedTextColor As Int, NonFocusedTextColor As Int, View As ASTextFieldAdvanced_ViewTitle) As ASTextFieldAdvanced_Title
      • CreateASTextFieldAdvanced_TrailingIcon (Visible As Boolean, Icon As B4XBitmap, View As ASTextFieldAdvanced_ViewTrailingIcon) As ASTextFieldAdvanced_TrailingIcon
      • DesignerCreateView (Base As Object, Lbl As Label, Props As Map) As String
        Base type must be Object
      • Focus As Boolean
        Sets input focus
        Returns True if the focus has shifted
        Always retuns True in B4J
      • FontToBitmap (text As String, IsMaterialIcons As Boolean, FontSize As Float, color As Int) As B4XBitmap
      • getBackgroundColor As Int
      • getBackgroundPanel As B4XView
      • getBottomHeight As Float
        Call Refresh if you change something
      • getButtonTextLabel As B4XView
      • getClearAndRevealButtonColor As Int
        Call Refresh if you change something
      • getClearButtonLabel As B4XView
      • getCounter As ASTextFieldAdvanced_Counter
        Call Refresh if you change something
      • getFocusedShapeColor As Int
      • getHint As ASTextFieldAdvanced_Hint
        Call Refresh if you change something
      • getInformation As ASTextFieldAdvanced_Information
        Call Refresh if you change something
      • getisPasswordMode As Boolean
      • getisRevealed As Boolean
      • getKeyboardType As String
      • getLeadingIcon As ASTextFieldAdvanced_LeadingIcon
        Call Refresh if you change something
      • getLeftGap As Float
        Default: 10dip
        Call Refresh if you change something
      • getMaskText As String
      • getNativeTextField As TextField
        Gets the native TextField view
      • getNativeTextFieldMultiline As TextArea
      • getNativeTextFieldPassword As TextField
        Gets the native TextField view
      • getNonFocusedShapeColor As Int
      • getPrefix As ASTextFieldAdvanced_Prefix
        Call Refresh if you change something
      • getReadOnly As Boolean
        Call Refresh if you change something
      • getRequiredField As Boolean
      • getRequiredFieldColor As Int
      • getRevealButtonLabel As B4XView
      • getShowClearButton As Boolean
        Call Refresh if you change something
      • getShowRevealButton As Boolean
        Call Refresh if you change something
      • getSuffix As ASTextFieldAdvanced_Suffix
        Call Refresh if you change something
      • getText As String
      • getTextField As B4XView
      • getTextFieldCornerRadius As Float
      • getTextFieldMultiline As B4XView
      • getTextFieldPassword As B4XView
      • getTextFull As String
        Gets the full text, with Prefix and Suffix
      • getTitle As ASTextFieldAdvanced_Title
        Call Refresh if you change something
      • getTrailingIcon As ASTextFieldAdvanced_TrailingIcon
        Call Refresh if you change something
      • HideDisplayMissingField As String
        <code>AS_TextFieldAdvanced_1.HideDisplayMissingField</code>
      • Initialize (Callback As Object, EventName As String) As String
      • IsInitialized As Boolean
        Tests whether the object has been initialized.
      • PasswordScore As Int
        1 = Weak
        2 = Medium
        3 = Strong
      • Refresh As String
      • setBackgroundColor (Color As Int) As String
      • setBottomHeight (Height As Float) As String
      • setButtonText (Text As String) As String
      • setButtonText2 (Text As String)
        Without TextChanged Event
      • setClearAndRevealButtonColor (Color As Int) As String
      • setFocusedShapeColor (Color As Int) As String
      • setLeftGap (Gap As Float) As String
      • setMaskText (Mask As String) As String
      • setNonFocusedShapeColor (Color As Int) As String
      • setReadOnly (ReadOnly As Boolean) As String
      • setRequiredField (Required As Boolean) As String
        Call Refresh if you change something
      • setRequiredFieldColor (Color As Int) As String
        Call Refresh if you change something
      • setReveale (Revealed As Boolean) As String
      • setShowClearButton (Show As Boolean) As String
      • setShowRevealButton (Show As Boolean) As String
      • setText (Text As String) As String
      • setText2 (Text As String)
        Without TextChanged Event
      • setTextColor (Color As Int) As String
      • setTextFieldCornerRadius (CornerRadius As Float) As String
      • ShowDisplayMissingField (InformationText As String) As String
        Call this function to inform the user that not all required fields are filled in.
        Call HideDisplayMissingField to remove it
        <code>AS_TextFieldAdvanced_1.ShowDisplayMissingField("This field is required")</code>
    • Properties:
      • BackgroundColor As Int
      • BackgroundPanel As B4XView [read only]
      • BottomHeight As Float
        Call Refresh if you change something
      • ButtonText
      • ButtonText2
        Without TextChanged Event
      • ButtonTextLabel As B4XView [read only]
      • ClearAndRevealButtonColor As Int
        Call Refresh if you change something
      • ClearButtonLabel As B4XView [read only]
      • Counter As ASTextFieldAdvanced_Counter [read only]
        Call Refresh if you change something
      • FocusedShapeColor As Int
      • Hint As ASTextFieldAdvanced_Hint [read only]
        Call Refresh if you change something
      • Information As ASTextFieldAdvanced_Information [read only]
        Call Refresh if you change something
      • isPasswordMode As Boolean [read only]
      • isRevealed As Boolean [read only]
      • KeyboardType As String [read only]
      • LeadingIcon As ASTextFieldAdvanced_LeadingIcon [read only]
        Call Refresh if you change something
      • LeftGap As Float
        Default: 10dip
        Call Refresh if you change something
      • MaskText As String
      • NativeTextField As TextField [read only]
        Gets the native TextField view
      • NativeTextFieldMultiline As TextArea [read only]
      • NativeTextFieldPassword As TextField [read only]
        Gets the native TextField view
      • NonFocusedShapeColor As Int
      • Prefix As ASTextFieldAdvanced_Prefix [read only]
        Call Refresh if you change something
      • ReadOnly As Boolean
        Call Refresh if you change something
      • RequiredField As Boolean
        Call Refresh if you change something
      • RequiredFieldColor As Int
        Call Refresh if you change something
      • RevealButtonLabel As B4XView [read only]
      • Reveale
      • ShowClearButton As Boolean
        Call Refresh if you change something
      • ShowRevealButton As Boolean
        Call Refresh if you change something
      • Suffix As ASTextFieldAdvanced_Suffix [read only]
        Call Refresh if you change something
      • Text As String
      • Text2
        Without TextChanged Event
      • TextColor
      • TextField As B4XView [read only]
      • TextFieldCornerRadius As Float
      • TextFieldMultiline As B4XView [read only]
      • TextFieldPassword As B4XView [read only]
      • TextFull As String [read only]
        Gets the full text, with Prefix and Suffix
      • Title As ASTextFieldAdvanced_Title [read only]
        Call Refresh if you change something
      • TrailingIcon As ASTextFieldAdvanced_TrailingIcon [read only]
        Call Refresh if you change something
Changelog
  • 1.00
    • Release
  • 1.01 (read more)
    • Add Designer Property LeadingIcon - An icon which is placed in front of the text and has its own click event
    • Add Designer Property TrailingIcon - An icon which is placed behind the text and has its own click event
    • Add Event LeadingIconClick
    • Add Event TrailingIconClick
    • Add some more properties
  • 1.02
    • Add Type ASTextFieldAdvanced_Title
    • Add Type ASTextFieldAdvanced_Information
    • Add Type ASTextFieldAdvanced_Counter
    • Add Type ASTextFieldAdvanced_Hint
    • Add Type ASTextFieldAdvanced_LeadingIcon
    • Add Type ASTextFieldAdvanced_TrailingIcon
    • Removed some properties, they are now in the new types
    • BugFixes
  • 1.03 (read more)
    • Add Type ASTextFieldAdvanced_Prefix
    • Add Type ASTextFieldAdvanced_Suffix
    • Add Designer Properties Prefix, PrefixText, Suffix, SuffixText
    • Add get TextFull - Gets the full text, with Prefix and Suffix
    • BugFixes
  • 1.04
    • BugFixes
  • 1.05
    • BugFixes
  • 1.06
    • BugFixes
    • Add Designer Property ReadOnly - Disables the user input
      • Default: False
  • 1.07
    • BugFixes
    • Add "Multiline" to the designer property "Mode"
    • New Multiline mode
  • 1.08
    • Multiline BugFixes
  • 1.09
    • Add Focus - Sets input focus
  • 1.10
    • BugFixes
    • get Reveale is renamed to isRevealed
  • 1.11
    • Add Designer Property TextAlignment
      • Default: Left
  • 1.12
    • Add set Text2 - Sets the text, without TextChanged Event
    • Add set ButtonText2 - Sets the button text, without TextChanged Event
  • 1.13
    • BugFixes
  • 1.14
    • ClearButtonClick
  • 1.15
    • BugFix
  • 1.16
    • BugFixes
    • Performance improvements
  • 1.17
    • BugFixes - Character delimiter (Counter = True)
    • B4J Only - Click on the TextField to focus it
  • 1.18
    • BugFix - ReadOnly = True - ClearButton and RevealButton are now also read only
  • 1.19 (read more)
    • Add FocusedShapeColor
      • Default: White with alpha 0 = Transparent
    • Add set TextColor
    • Add Designer Property TextFieldCornerRadius
      • Default: 5dip
    • B4J BugFix - The EnterPressed Event was not triggered
  • 1.20 (read more)
    • BugFixes
    • Add Designer Property StrengthIndicator - Password strength indicator
      • None|Line|Segmented
      • Default: None
  • 1.21 (read more)
    • Add Designer Property RequiredField - if True the field is a required field and is marked with a colored star
      • Default: False
    • Add Designer Property RequiredFieldColor
      • Default: Red
    • Add ShowDisplayMissingField - Call this function to inform the user that not all required fields are filled in
      • Call HideDisplayMissingField to remove it
    • Add HideDisplayMissingField - Removes the user notification from ShowDisplayMissingField
    • Add Designer Property Mask - You can use masks now
      • Default: None
    • Add Designer Property MaskText
      • Example: XXX.XXX.XXX-XX
  • 1.22
    • Add get and set MaskText
  • 1.23
    • BugFixes
    • RevealButton and ClearButton TextColor - Can now also be seen in light mode
    • Add Designer Property ClearAndRevealButtonColor - is per default transparent
      • If the alpha value is set to 0, then a color that matches the background color is automatically used
    • Add Designer Property FocusedTitleTextColor
      • Default: White
    • Add Deigner Property NonFocusedTitleTextColor
      • Default: White
      • Would interfere too much with the design of already existing layouts if another white would be used
    • Add Designer Property NonFocusedShapeColor
  • 1.24
    • Add new Type ASTextFieldAdvanced_TextFieldProperties
    • Properties
      • FocusedShapeColor
      • NonFocusedShapeColor
      • CornerWidth - NEW
      • CornerRadius
  • 1.25
    • BugFixes
  • 1.26
    • BugFixes
  • 1.27
    • BugFixes
  • 1.28
    • Multiline TextFields supports now the clear button
    • The action button have now a fixed HeightWidth = 24dip
  • 1.29
    • BugFixes
  • 1.30
    • Add get and set LeadingWidth
    • Add get and set TrailingWidth
  • 1.31
    • B4A BugFix
  • 1.32
    • Add Designer Property CounterTextColor
      • Default: White
    • Add Designer Property InfoTextColor
      • Default: White
  • 1.33
    • Add Designer Property Underline - A line is visible on the textfield
      • Default: False
      • If true the ShapeColor ist used for this underline
    • Add get UnderlinePanel
  • 1.34
    • BugFix - If ShowRevealButton = True and PasswordField = False - Then the gap was still present at the end of the textfield
  • 1.35
    • BugFix - if you set the Counter or CounterMax, then one emoji is now counting as one
  • 1.36
    • BugFix - The hint text was only renewed if the TextField had no text
    • B4I BugFix - Readonly on Multiline did not work
  • 1.37
    • B4I BugFix - Readonly on Multiline did not work
  • 1.38 (read more)
    • Breaking Change - ButtonText and ButtonText2 have been removed and now work with .Text and .Text2
      • It confuses me every time, especially when I don't know that it's a button
    • A few functions have been made private as they should not be public
    • Button Mode BugFixes
    • Add Mode "ComboBox"
    • Add Event ComboBoxSelectedIndexChanged
    • Add set SetItems
    • Add get and set SelectedIndex

Have Fun :)
 

Attachments

  • AS TextFieldAdvanced Example.zip
    96.5 KB · Views: 897
  • AS_TextFieldAdvanced.b4xlib
    14.2 KB · Views: 66
Last edited:

incendio

Well-Known Member
Licensed User
Longtime User
Perhaps you could consider my request :
Add field type date, integer, float, and formatted field.

1. Type date, read only, when user clicked it, date picker shows

2. Type integer, virtual keyboard change to numerical buttons only but no fraction can be inputted

3. Type float, same as type integer, except users can input pre-defined fraction, for example float(2), mean that users can input only 2 decimal

3. Formatted fied, only apply to type integer and float.
To format text fied value when not in focus.

Example, text field has a value 1000, when cursor not focus, it will display as 1,000, but when cursor is in focus, it will display 1000.
 

Alexander Stolte

Expert
Licensed User
Longtime User
1. Type date, read only, when user clicked it, date picker shows
Set the mode to "button" and use the ButtonCLick event to add the AS FloatingPanel on it.
If you need inspiration then look on the gifs in this thread:
For Date, use the AS DatePicker, for Time use AS WheelDateTimePicker and load this to the AS FloatingPanel panel.

2. Type integer, virtual keyboard change to numerical buttons only but no fraction can be inputted
Set KeyboardType to Numbers
3. Type float, same as type integer, except users can input pre-defined fraction, for example float(2), mean that users can input only 2 decimal
Set KeyboardType to Decimal
 

behnam_tr

Active Member
Licensed User
Longtime User
Perhaps you could consider my request :
Add field type date, integer, float, and formatted field.

1. Type date, read only, when user clicked it, date picker shows

2. Type integer, virtual keyboard change to numerical buttons only but no fraction can be inputted

3. Type float, same as type integer, except users can input pre-defined fraction, for example float(2), mean that users can input only 2 decimal

3. Formatted fied, only apply to type integer and float.
To format text fied value when not in focus.

Example, text field has a value 1000, when cursor not focus, it will display as 1,000, but when cursor is in focus, it will display 1000.

Set KeyboardType to Numbers
Set KeyboardType to Decimal

its only available in b4a

in b4j I am using this codes for any textfields:

 

incendio

Well-Known Member
Licensed User
Longtime User
Set the mode to "button" and use the ButtonCLick event to add the AS FloatingPanel on it.
If you need inspiration then look on the gifs in this thread:
For Date, use the AS DatePicker, for Time use AS WheelDateTimePicker and load this to the AS FloatingPanel panel.


Set KeyboardType to Numbers

Set KeyboardType to Decimal
I know, it can be achieved by set the keyboard, but it is simpler if it already built in in this library.

Imagine an app in B4A with lots of B4xPages, each page have lots of different type of text fields.
Every time focus changed, keyboard type must be set according to field type.
 
Last edited:

Soheyl

Member
Licensed User
Longtime User
It's fantastic 👏 thanks
Is there any focus property? Like Setfocus to open keyboard in programming
 

Claudio Oliveira

Active Member
Licensed User
Longtime User
Amazing view indeed. 💯
I have a question, though: The PasswordRevealChanged event is passing True when the text field is hidden, while on the other hand it´s passing False when the text is shown. The Reveale property reflects this - which is expected.
In other words: If your text is hidden and you get the Reveale property, you're gonna get the value True, opposed to the actual view state.
Is this the intended behaviour?

By the way, maybe you might change Reveale property name to Revealed.

Apart from this, congrats for the view. Amazing as usual! 👏👏👏
 

behnam_tr

Active Member
Licensed User
Longtime User
Hi @Alexander Stolte

Error On b4j 9.30

B4X:
Waiting for debugger to connect...
Program started.
Error occurred on line: 229 (AS_TextFieldAdvanced)
java.lang.RuntimeException: Type does not match (class javafx.scene.control.TextField)
    at anywheresoftware.b4a.objects.B4XViewWrapper.typeDoesNotMatch(B4XViewWrapper.java:573)
    at anywheresoftware.b4a.objects.B4XViewWrapper.SetTextAlignment(B4XViewWrapper.java:448)
    at b4j.example.as_textfieldadvanced._designercreateview(as_textfieldadvanced.java:1627)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:629)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:237)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:167)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at anywheresoftware.b4a.BA.raiseEvent2(BA.java:109)
    at anywheresoftware.b4a.shell.ShellBA.raiseEvent2(ShellBA.java:98)
    at anywheresoftware.b4j.objects.CustomViewWrapper.AfterDesignerScript(CustomViewWrapper.java:79)
    at anywheresoftware.b4j.objects.LayoutBuilder.loadLayout(LayoutBuilder.java:110)
    at anywheresoftware.b4j.objects.PaneWrapper.LoadLayout(PaneWrapper.java:101)
    at b4j.example.main._appstart(main.java:77)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:629)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:237)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:167)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at anywheresoftware.b4a.BA.raiseEvent2(BA.java:109)
    at anywheresoftware.b4a.shell.ShellBA.raiseEvent2(ShellBA.java:98)
    at anywheresoftware.b4a.BA.raiseEvent(BA.java:96)
    at b4j.example.main.start(main.java:38)
    at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$8(LauncherImpl.java:863)
    at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$7(PlatformImpl.java:326)
    at com.sun.javafx.application.PlatformImpl.lambda$null$5(PlatformImpl.java:295)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sun.javafx.application.PlatformImpl.lambda$runLater$6(PlatformImpl.java:294)
    at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
    at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
    at com.sun.glass.ui.win.WinApplication.lambda$null$4(WinApplication.java:185)
    at java.lang.Thread.run(Thread.java:750)
 

james_sgp

Active Member
Licensed User
Longtime User
I have 2 fields for 'passwords' but unless I tap the 'reveal' buttons I`m they are returning as empty:

B4X:
    If reg_pass.Text = "" Or reg_pass2.Text = "" Then
        MsgboxAsync("Please enter PASSWORDS", "E R R O R")
        Return

Can someone let me know what I`m doing wrong...

James
 

james_sgp

Active Member
Licensed User
Longtime User
Update
  • 1.15
    • BugFix

Thanks for reporting, have a nice day!
Mmm....now its telling me that other boxes have no text (default, no password, icons, etc):

B4X:
    If reg_name.Text = "" Then
        MsgboxAsync("Please enter a NAME", "E R R O R")
        Return
 
Top