views:

47

answers:

1

I have a tabhost, e.g:
final TabHost tabs = getTabHost(); tabs.setup(); TabHost.TabSpec spec = null; spec = tabs.newTabSpec("search"); spec.setContent(new Intent(this, Search.class)); spec.setIndicator("search"); tabs.addTab(spec); in this tabhost is a Intent,and in the activity must change to other activity, question is I hope the other actitivy at same tabhost switch? Can do this?

A: 

hi enricozhang,

I had this problem almost a 3 months ago. you can not replace the activity. Because activities are open in new screens. so you have to use the views and layout to achieve what you are want to do. use the setVisiblity and isShown mehtods you can hide and release yours view. Hope it make some sense on it. Thanks.

Note: when you get the correct answer or idea. you have to accept it and upvote it. then only folks will interested to answer on your profile.

Praveen Chandrasekaran