I hope this request gets through, the last message I sent earlier today seems to have disappeared in the ether - and it took me <ages> to write.
I am sure I have seen the answer to this somewhere in this Forum but I can't find any search terms that will bring it up.
I am looking for an easier way to set the same attributes for a series of views than simply running through them one by one. A loop of some kind, or even a sub which will take the name of the View, like SetAttributes(NameofView). When you have a total of 60 or more edittext boxes spread across different panels in different tabs it gets rather tedious to do this:
Thanks
Caravelle
I am sure I have seen the answer to this somewhere in this Forum but I can't find any search terms that will bring it up.
I am looking for an easier way to set the same attributes for a series of views than simply running through them one by one. A loop of some kind, or even a sub which will take the name of the View, like SetAttributes(NameofView). When you have a total of 60 or more edittext boxes spread across different panels in different tabs it gets rather tedious to do this:
B4X:
Dim r As Reflector
TxtUpdSerial.Background = ButtonGradient(Array As Int(Colors.RGB(255, 255, 102), Colors.RGB(240,240,28)))
r.Target = TxtUpdSerial
r.RunMethod4("setPadding", Array As Object(0, 1dip, 0, 0), _
Array As String("java.lang.int", "java.lang.int", "java.lang.int", "java.lang.int"))
TxtUpdId.Background = ButtonGradient(Array As Int(Colors.RGB(255, 255, 102), Colors.RGB(240,240,28)))
r.Target = TxtUpdId
r.RunMethod4("setPadding", Array As Object(0, 1dip, 0, 0), _
Array As String("java.lang.int", "java.lang.int", "java.lang.int", "java.lang.int"))
TxtUpdMaker.Background = ButtonGradient(Array As Int(Colors.RGB(255, 255, 102), Colors.RGB(240,240,28)))
and again
and again
and again...
Thanks
Caravelle