I have textView that I would like to turn into a simple log of what stage of a loop the program is currently in.
For example if I press a button:
public void doThis(View view) {
for (int j = 1; j <= 10; j++) {
my_text.setText(j+"");
}
}
This overwrites the text in the textView though. How would I go about creating something where the textView would say:
1
2
3
4
5
6
7
8
9
10
You can append text my_text.append(j+"\n");
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With