Error on Android Handler update interface -
handler handler = new handler() { public void handlemessage(message msg) { super.handlemessage(msg); returnshow.settext(smsg);//returnshow edittext returnshow.setselection(returnshow.length()); } }; class readthread extends thread { public void run() { smsg = "..."; handler.sendmessage(handler.obtainmessage()); } }
everytime run, settext
line have error, can't figure out why?
thanks help.
make sure returnshow
initialized before setting it..
something like..
returnshow = (edittext)findviewbyid(r.id.edittext);
Comments
Post a Comment