I have a problem with activities. I have a 4 activities. First is menu, second and thirth are other menus and fourth is screen with help. In every for 3 menu screens I have a button which start activity help. In help activity I have a info about application and button. I want to this button when user use it he back to last active activity. For better understanding: when I am in first menu and click help button, activity “help” is starting and when I click button “back”, activity “menu1” is starting. Algorithm must be the same for other menus. Can you help me?
Share
Normally, if you start activity Y from activity X, when activity Y finishes, the control automatically returns to activity X.
Thus, let’s say you have three menu activities A, B, C and help activity D. Then, if you do
A -> D, then when D finishes, you’ll be back on A. If your flow isA -> B -> D, then after D finishes, you should end up back on B. Lastly, if your flow isA -> B -> C -> D, then upon finishing of D, you should come back to C. This is something Android should do for you automatically without you having to code anything special.Or did I misunderstood your requirements?