I'm Trying To Implement A New Activity After A User Logs Into His/her Account, But The App Keeps Crashing After Sign In Is Complete
I am trying to implement a new activity after a user logs into his account, but the app keeps crashing after sign in is completes. I am also trying to get this new activity to open
Solution 1:
Change this line
startActivity(newIntent("com.xpro.salccregistry.SCANS"));
to
startActivity(newIntent(CurrentAct.this, NextActivity.class));
and check.
P.S: Make sure the NextActivity is declared in manifest file as follows:
<applicationandroid:icon="@drawable/ic_launcher"android:label="@string/app_name"android:theme="@style/AppTheme" ><activityandroid:name=".FirstActivity"android:label="@string/title_activity_main" ><intent-filter><actionandroid:name="android.intent.action.MAIN" /><categoryandroid:name="android.intent.category.LAUNCHER" /></intent-filter></activity><activtyandroid:name="com.xpro.salccregistry.SCANS"/></application>Hope this helps.
Solution 2:
Please regiser your activity :
You didn't register your activity in AndroidMenifest.xml file :
See this : http://prntscr.com/2qlobiSolution 3:
try this it just work with me
startActivity(newIntent(this,<class you want to start>.class));
example :
startActivity(newIntent(this,ActivityTwo.class));
Post a Comment for "I'm Trying To Implement A New Activity After A User Logs Into His/her Account, But The App Keeps Crashing After Sign In Is Complete"