Java 我的应用程序没有';当我运行项目时,emulator上不会显示

Java 我的应用程序没有';当我运行项目时,emulator上不会显示,java,android,android-emulator,Java,Android,Android Emulator,当我尝试运行该项目时,它会在模拟器上成功安装,但模拟器不会在其“应用程序”菜单中显示“我的应用程序启动器”图标。但是,它会在“设置>应用程序>管理应用程序>所有应用程序”的“已安装应用程序”中显示我的应用程序,这意味着已安装应用程序。但它没有运行 <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="

当我尝试运行该项目时,它会在模拟器上成功安装,但模拟器不会在其“应用程序”菜单中显示“我的应用程序启动器”图标。但是,它会在“设置>应用程序>管理应用程序>所有应用程序”的“已安装应用程序”中显示我的应用程序,这意味着已安装应用程序。但它没有运行

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thenewboston.travis"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".Splash"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.SPLASH" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".Main"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MAIN" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name=".Menu"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MENU" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    </application>

     </manifest>
舱单:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thenewboston.travis"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".Splash"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.SPLASH" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".Main"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MAIN" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name=".Menu"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MENU" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    </application>

     </manifest>


//试试这里的“android.intent.action.MAIN”//

确保启动活动的目的过滤器已在清单中正确声明,以便在启动器中显示

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thenewboston.travis"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".Splash"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.SPLASH" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".Main"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MAIN" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name=".Menu"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MENU" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    </application>

     </manifest>
假设您希望“Splash”成为您的主要活动,则将其声明更改为此(特别是意图过滤器操作)

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thenewboston.travis"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".Splash"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.SPLASH" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".Main"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MAIN" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name=".Menu"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MENU" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    </application>

     </manifest>


您的意图过滤器操作不是android默认设置的一部分(也是启动器通常寻找的)。只有设计用于查找操作“com.thenewboston.travis.SPLASH”的启动器才会看到您的活动

DDMS中的LogCat中是否有错误?发布您的
AndroidManifest.xml
@tim LogCat中没有错误
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.thenewboston.travis"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="8"
    android:targetSdkVersion="16" />

<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".Splash"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.SPLASH" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <activity
        android:name=".Main"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MAIN" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name=".Menu"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="com.thenewboston.travis.MENU" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    </application>

     </manifest>