Click here to Skip to main content
15,886,026 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello everyone , I want to add to my new Android project an Activity as it will run at the first place after the add.There is anyone who know how to do that !

[edit]SHOUTING removed (and the multiple exclamation marks) - OriginalGriff[/edit]
Posted
Updated 12-May-15 0:17am
v2
Comments
OriginalGriff 12-May-15 6:17am    
DON'T SHOUT. Using all capitals is considered shouting on the internet, and rude (using all lower case is considered childish). Use proper capitalization if you want to be taken seriously.
Mohibur Rashid 12-May-15 6:27am    
First add your activity. Then open your mainfest.xml or whatever. There you will get an option to set your startup activity. Besides search on google. So many answers are there..
Member 11683950 12-May-15 6:43am    
thank you very much for the answer .

1 solution

Hello,

Open your manifest file and find newly added activity.
Add Filter inside it, whole code should look like this:

<activity>
           android:name=".YOUR_NEW_ACTIVITY_NAME"
           android:label="@string/title_activity_new"
           android:theme="@android:style/Theme.Holo.Light.NoActionBar.Fullscreen" >

           <intent-filter android:label="@string/app_name" xmlns:android="#unknown">
               <action android:name="android.intent.action.MAIN" />
               <category android:name="android.intent.category.LAUNCHER" />
           </intent-filter>

       </activity>
 
Share this answer
 
v2
Comments
Member 11683950 13-May-15 5:00am    
thanks for the answer ,i'm already solve the probleme by using your solution .

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900