I am a beginner in app development. At first, everything went great, the app showed up both on the emulator and the phone without crashing. After a while, the icon of the app won't show up in the app drawer, and there is no any other way that I could access the app anymore. I recheck everything, there isn't any apparent error in my code, when i ran the program in the emulator and the phone, eclipse showed that the app was installed successfully, but the app won't turn on automatically like it used to, and there is no app icon for me to open the app. Please help!
Attached is my code from the Androidmanifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.trial1"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="17" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.trial1.Splash"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.SPLASH" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.example.trial1.Mainscreen"
android:label="@string/app_name" >
<intent-filter>
<action android:name="com.example.trial1.MAINSCREEN" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name="com.example.trial1.startingPoint"
android:label="@string/app_name" >
<intent-filter>
<action android:name="com.example.trial1.STARTINGPOINT" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name="com.example.trial1.Menu"
android:label="@string/app_name" >
<intent-filter>
<action android:name="com.example.trial1.MENU" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name="com.example.trial1.TextPlay"
android:label="@string/app_name" >
</activity>
</application>
</manifest>
You have missed to put the action in your launcher activity
<action android:name="android.intent.action.MAIN" />
your correct code look like
<activity
android:name="com.example.trial1.Splash"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<action android:name="android.intent.action.SPLASH" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
I had the same problem. This worked for me:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.