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 8092505
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T20:17:49+00:00 2026-06-05T20:17:49+00:00

My Application has 3 activities (MainActivity,SampleActivity,TempActivity) and Application have to start from MainActivity because

  • 0

My Application has 3 activities (MainActivity,SampleActivity,TempActivity) and Application have to start from MainActivity because i register it in AndroidManifest as

    <activity
        android:name=".MainActivity"
        android:configChanges="keyboardHidden|orientation"
        android:label="@string/app_name"
        android:launchMode="singleTask"
        android:screenOrientation="landscape"
        android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".TempActivity"
        android:configChanges="keyboardHidden|orientation"
        android:label="@string/app_name"
        android:launchMode="singleTask"
        android:screenOrientation="landscape"
        android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen" >
    </activity>

    <activity
        android:name=".SampleActivity"
        android:configChanges="keyboardHidden|orientation"
        android:label="@string/app_name"
        android:launchMode="singleTask"
        android:screenOrientation="landscape"
        android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen">
     </activity>

when i switch from MainActivity to TempActivity and come back to MainActivity and then close the Application then often it starts from TempActivity.
after this wrong behavior when ever i start my application it starts from Wrong Activity(TempActivity).
Please help me in this problem

  • 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-06-05T20:17:50+00:00Added an answer on June 5, 2026 at 8:17 pm

    when u go from TempActivity activity to MainActivity u give finish()
    example:
    Intent myIntent = new Intent(TempActivity.this, MainActivity .class);
    startActivity(myIntent);
    finish();

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

Sidebar

Related Questions

I'm working on an Android application that has several Activities. In it I have
I have three activities in my android app. First activity is main application screen
I have an Android Application that has four activities. None is very large and
I have a problem : My application has several activities ( e.g. StartActivity, MainActivity
An Android application has two activities. Activity A shows a list of items. Activity
In my application I have several activities, the main screen has 4 buttons that
I have an android application that has 3 activites. For the 1st and 2nd
In my application has two Activities. One is main activity and other is activity
I have an application which has two Activities, let's call them A and B.
I have a TabActivity that is the base Activity in my application. From the

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.