Hello All:
I am creating an application in which I am using menus on every screen for the user to navigate. In my application, I have Screen1–> comes as home screen when the user logs in
Screen2–> user goes to this screen to perform some operations. Now on Screen2 I want to have menu option to let the user go to home screen.
But to start the activity we do
startActivity(new Intent(Home.this, Screen2.class));
But, I want to use the existing home screen which was created when the used logged in and then using onresume method I can update the home screen.
Can anybody please tell me how to use the existing intents or activity to provide menu options?
Thanks
Ashwani
Ashwani,
I believe this can be done with a
setFlags()call on yourIntentusing theFLAG_ACTIVITY_REORDER_TO_FRONTflag. If screen 1 still exists it will bring it to the foreground. The documentation doesn’t seem to specify, but I assume it launches a new Activity of Screen 1 was killed.