I have one layout with 100 blank EditTexts, all named based on their row / column IDs (e.g. box0101, box0102 etc.).
I then have another layout with 100 TextViews in exactly the same layout with one letter in each, named using the same convention (answerbox0101, answerbox0102 etc.)
I want to write a loop that checks box0101 against answerbox0101, and so on until either one of the boxes does not match up, or it gets to 100 and all the boxes match.
I am fine with writing the logic of the loop, my issue is that i need the looping parameter to be part of the name of the EditText! How can I overcome this?
You can use Tag Property of View to set String Property, like if you are creating 100 editTexts, you can set tags of edit texts, like editText0101, editText0102, ... and same in answer editTexts answerbox0101, answerbox0102.... by this method you can get direct references of editText by tag name, by
findViewByTag()
method.