My Application has 5 different activities ( name them as A,B,C,D,E ) and there is a menu (made by buttons on bottom of the screen), to switch between A,B...E
when I am displaying A, there are some button by which the user goes on another activity A1 on top of A, then from there he goes into A12, so my activity stack is something like A>A1>A12, now the user click on menu button for B, then he goes on B1 from there . (Stack would be like A>A1>A12>B>B1) now if user press the button to switch back to A, so it should display A12, as it is on top of A.
how do I manage this scanario? I have no hint at all
I suggest you should create a tabHost contains all 5 Activity A, B, C, D, E.
After initialize tabHost, let hide this tab bar by calling:
And you should switch between each Activity like this:
So, when you are in A1 -> A2, and switch to Activity B, and use menu to switch back A, you're still in A2.
Hope it can help you.
Instead of buttons at bottom of the screen, use TabHost and ActivityGroup to display multiple activities under the selected tab.
Main activity:
The activty group: