B4J Question Is there a way in Android to reference a control name with numbers?

MrKim

Well-Known Member
Licensed User
Longtime User
In VBA I frequently do something like this when I have a large number of similar controls:
The below would Reference Buttons named Btn1, Btn2...Btn10
B4X:
Dim X as int
Open MyRecordset
For X = 1 to 10
    MyRecordset.Movenext
    MyForm.Controls("Btn" & Cstr(X)).Caption = MyRecordset.SomeValue
Next
Is there any similar way to reference controls in B4J?
 

Cableguy

Expert
Licensed User
Longtime User
Search for "array of views"

Also, you posted on the wrong sub forum
 
Last edited:
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…