Eclipse中的控制台说:
[2014-03-10 17:46:08 - MyFirstApp] ------------------------------
[2014-03-10 17:46:08 - MyFirstApp] Android Launch!
[2014-03-10 17:46:08 - MyFirstApp] adb is running normally.
[2014-03-10 17:46:08 - MyFirstApp] No Launcher activity found!
[2014-03-10 17:46:08 - MyFirstApp] The launch will only sync the application package on the device!
[2014-03-10 17:46:08 - MyFirstApp] Performing sync
[2014-03-10 17:46:17 - MyFirstApp] Uploading MyFirstApp.apk onto device 'TA88307T9S'
[2014-03-10 17:46:17 - MyFirstApp] Installing MyFirstApp.apk...
[2014-03-10 17:46:19 - MyFirstApp] Success!
[2014-03-10 17:46:19 - MyFirstApp] \MyFirstApp\bin\MyFirstApp.apk installed on device
[2014-03-10 17:46:19 - MyFirstApp] Done!
这是从在线导入Hello World应用程序之后。现在我希望在我的手机上找到一个应用程序图标来启动它,但我找不到它。如何启动应用程序?
在Merlevede回答之后,我的清单xml文件现在看起来像这样:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.myfirstapp"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="19" />
<intent-filter android:label="@string/app_name">
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:debuggable="true"
android:theme="@style/AppTheme" >
</application>
</manifest>
但问题仍然存在。
答案 0 :(得分:0)
问题出在您的Android Manifest xml文件中。您错过了主要活动的部分内容(MAIN
操作或LAUNCHER
类别)。
<activity android:name="mx.company.app.ActivityMain" android:label="@string/title_activity_main" >
<intent-filter android:label="@string/app_name">
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
答案 1 :(得分:0)
未找到Launcher活动!
因为日志说你没有Launcher Activity。要解决这个问题,可以根据您的要求将任何活动视为laucher
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.myfirstapp"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="19" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:debuggable="true"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.myfirstapp.MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>