Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7553165
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T10:58:27+00:00 2026-05-30T10:58:27+00:00

In my app I have couple activities. How to setup that every time user

  • 0

In my app I have couple activities. How to setup that every time user long press home and bring from background my app it display always main activity?

Cause right now if user hide the app and log press “home” button, my app coming back to the latest open activity, but then user press “back” button it close app, but than press app icon it coming back to main activity.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T10:58:28+00:00Added an answer on May 30, 2026 at 10:58 am

    If you want only your main activity to be in visible your “recent apps”, then in all your non-main activities, add this flag in your manifest:

    android:noHistory
    

    This will cause your main activity to remain on the activity stack, but remove all your activities from it.

    http://developer.android.com/guide/topics/manifest/activity-element.html#nohist

    Whether or not the activity should be removed from the activity stack
    and finished (its finish() method called) when the user navigates away
    from it and it’s no longer visible on screen — “true” if it should be
    finished, and “false” if not. The default value is “false”. A value of
    “true” means that the activity will not leave a historical trace. It
    will not remain in the activity stack for the task, so the user will
    not be able to return to it. This attribute was introduced in API
    Level 3.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a couple activities in my app that I would like to utilize
I have a couple of nagging compiler warnings for an app that I ported
I have a complex .NET Remoting server app that provides a couple of services.
SETUP : I have this app which has 4 activities in a linear path,
I have a couple of app engine urls that return pure JSON and this
I am working on an Android app and have a couple strings that I
I have a couple of models in a Rails app. Let's say it's Products
This is my first winform app in .NET... I have made a couple of
I have recently been rewriting some of my iphone app because a couple of
For the last couple months i have ben having some issues with my app.config

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.