>
> This is probably a very "newbie" question as i'm relatively new to the
> android sdk, but figured this would be good place to ask.
>
> Say you have a layout with several textviews that all have sequential
> IDs (ie, tBox1, tBox2, tBox3, etc). Is it possible to reference each
> box in a loop? Something like:
>
> do {
> iCount++;
> View tvBox1 = findViewById(R.id.tBox[iCount]);
> }
> while (iCount < 10);
You could create a static array of the IDs and iterate over the array.
--
Mark Murphy (a Commons Guy)
http://commonsware.com
Android App Developer Books: http://commonsware.com/books.html
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---