findViewById Argument Construction -
i have android app (written in android studio) i'm trying streamline. basically, 10 buttons on same screen each unique id of "button1" through "button10".
my question regards findviewbyid. understand takes integer argument , can work using findviewbyid(r.id.button1) etc how can make r.id.button1 part generic? eg how incorporate r.id.button1 part loop change text on buttons programatically? i've tried constructing argument part via "r.id.button" + z + "" (where z loops 1 10) argument isn't integer. missing?
many help...
simon
Comments
Post a Comment