What is the correct syntax to copy from EditText1 to Label1 when using Smart Strings and StdActionBar?
My log file shows the currentPage changes but the Label doesn't get updated.
Am using one btnChng button that is copied to the other panels.
Thanks in advance
My log file shows the currentPage changes but the Label doesn't get updated.
Am using one btnChng button that is copied to the other panels.
B4X:
Sub btnChng_Click
Log ("btnChng_Click currentPage is " & vpg.currentPage) 'writes "btnChng_Click currentPage is" with page number, in the Log
Dim strInputEdt As String=vpg.currentPage
Dim strOutputEdt As String= $"EditText${strInputEdt}"$
Log (strOutputEdt) 'writes EditText0.Text or EditText1.Text in the Log
Dim strInputLbl As String=vpg.currentPage
Dim strOutputLbl As String= $"Label${strInputLbl}"$
Log (strOutputLbl) ' 'writes Label0.Text or Label1.Text in the Log
' Label0.Text = EditText0.Text 'copies text from EditText0 to Label0
strOutputEdt = strInputLbl 'Log writes Label0 and EditText0, no text copied from EditText to Label
' "strInputLbl" = "strOutputEdt" 'Error = Illegal first word in line.
End Sub
B4X:
Log:
btnChng_Click currentPage is 0
EditText0.Text
Label0.Text
btnChng_Click currentPage is 1
EditText1.Text
Label1.Text
btnChng_Click currentPage is 2
EditText2.Text
Label2.Text