开发者

Facing problem when using back button in title bar

Friend's I have a problem when click the back button either in device or customised back button in header,it never back to show the list content,it simply shows the blank screen.

For example - -

I have list view - list1,in it's onclick event i move to next listview -list2, and from开发者_Go百科 list2 -onclick event i move to webview there i have back button in my titlebar,when i click it throws null pointer exception even from device back button also getting same,and the list show empty. where my webview is in New Activity.

Here my code for back button onClick, { finish(); } How can i resolve it.

Thanks in advance.


override this method "onBackPressed"

public void onBackPressed(){

}

and also call this method at back button click...it will bring you to previous activity

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜