Tabactivity That Create An Intent Onclick Button But The Tabhost Of Activity Receiver Disappear
I have 2 activity: A, B. The first is an TabActivity and the second an Activity. Inside A i have a clickable button that make an intent to call the other activity. public class A
Solution 1:
The android way to automatically change tab is:
tabHost.setCurrentTab(tab);
and not using:
startActivity(intent);
To use it on all your Activity the best way is to set your TabHost public and static.
Solution 2:
whenever you click a button you call an activity which is not child activity of tab activity. so tabhost is disapear. call activity b in tab activity just like this
tabHost.addTab(tabHost.newTabSpec("Tab")
.setIndicator("Tab")
.setContent(newIntent(this, b.class)
));
Post a Comment for "Tabactivity That Create An Intent Onclick Button But The Tabhost Of Activity Receiver Disappear"