#Event: TextChanged (Old As String, New As String)
Private Sub flEditText1_TextChanged (Old As String, New As String)
CallSubDelayed3(CallBack, EventName & "_TextChanged", Old, New)
End Sub
Thanks, I add above code to the class, it works well in B4A, but not in b4i, there are no errors or warnings during debugging, can't find the reason.Add this code to the class:
B4X:#Event: TextChanged (Old As String, New As String) Private Sub flEditText1_TextChanged (Old As String, New As String) CallSubDelayed3(CallBack, EventName & "_TextChanged", Old, New) End Sub
You will see an "unexpected event" warning in the logs, in debug mode. Ignore it.
Many thanks,I try and it works well in B4I. There is one thing I don’t understand. I don’t know how to represent the first parameter. I left it blank, but it doesn’t affect the result. for example:True. It is related to the way the input is handled. Go over the code and raise this event whenever flEditText1.Text is set.
Private Sub numpadButton_Click
Dim b As Button = Sender
If b.Text = "." And flEditText1.Text.Contains(".") Then Return
flEditText1.Text = flEditText1.Text & b.Text
flEditText1_TextChanged ("", flEditText1.Text)' I left first parameter blank'
End Sub