0

I have 2 activities in my app. The A activity is the launcher one. When I run the app the very first time, the launcher activity runs, but when I press the home button and restart the app from there by clicking the app icon, I always get the B activity running.
I want to make sure that the activity A should always run when starting the app.

This is the manifest code:

 <application
        android:icon="@drawable/icon"
        android:label="@string/app_name" >
        <activity
            android:name="com.velosys.smsManager.Activities.a"
            android:clearTaskOnLaunch="true"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name="com.velosys.smsManager.Activities.b" />
</application>

I have searched a lot for this but did not get any clue.

Adinia
  • 3,722
  • 5
  • 40
  • 58
user1726619
  • 941
  • 2
  • 18
  • 39

1 Answers1

1

Maybe android:launchMode="singleInstance" on activity B will get it done?

Nirali
  • 13,571
  • 6
  • 40
  • 53