I had made 5 textviews, textview1 to textview5. Then I created a textview array like this:-
TextView tvArr[] = new TextView[] { textview1, textview2, textview3, textview4, textview5 };
When I am using the setText method, it is throwing NullPointerException -
tvArr[3].setText("Done");
Please help me find out what I've missed out, and thanks in advance...
Edit: I want to find out how the set text method is throwing NullPointerException, I am not asking to troubleshoot my code...