How to register a new activity in AndroidManifest.xml?

I always get an error message when launching my created application, and based on my research, I did not register my activity in the manifest. How to register a new activity in AndroidManifest.xml?

+9
android
Dec 19 '10 at 6:33
source share
3 answers

Assuming you are using Eclipse,

Go to Android Manifest , go to the Applications tab (below), click "Add", select "Activity". Right next to Name: Click Browse for a list of available actions, just add it and install! :)

You can correctly change the XML manifest. It is for you.

+8
Dec 19 '10 at 6:39
source share
  <activity android:name="com.kl.android.ReadSMS.ViewSMS" /> 
+6
Dec 19 '10 at 6:35
source share

just use the class name after '.' as below

 <activity android:name=".ViewSMS"/> 
+6
Dec 19 '10 at 12:24
source share



All Articles