Is it possible to update this textView as follows ? new Thread(new Runnable() { @Override public void run() { textView.setText("Hello World"); } }).start();

Question:Is it possible to update this textView as follows ? new Thread(new Runnable() { @Override public void run() { textView.setText("Hello World"); } }).start();

1.Yes, it is possible and it's recommended to use its own thread to update views

2.No, because system throws a Fatal Exception: "Only the original thread that created a view hierarchy can touch its views"

3.both (a) and (b)

4.None of the above


Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!