应用程序出现在“管理应用程序”中,但不在主菜单上

发布于 2024-12-22 16:38:01 字数 919 浏览 4 评论 0原文

我正在使用 Eclipse 制作 Android 应用程序。我以前用过,没有遇到这个问题。控制台说一切安装正常,所以我有点困惑。我不确定 logcat 中的相关内容,但如果您认为这有帮助,我可以发布它。

我已经以不同的顺序重新启动了 Eclipse、ADB、模拟器和 Mac 多次,但没有任何帮助。我知道这一定很简单,但我已经几个月没有玩过这个了。

清单:

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

<uses-sdk android:minSdkVersion="10" />

<application
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name" >
</application>
<activity android:name=".pinpoint" android:label="pinpoint">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
</activity>

I'm using Eclipse to make an Android app. I've used it before and not had this problem. The console says everything installed ok, so I'm a little confused. I'm not sure what is relevant from logcat, but I can post it if you think that would help.

I've restarted Eclipse, ADB, the emulator, and the Mac several times in various orders and nothing has helped. I know it must be something simple but I haven't played around with this in a few months.

Manifest:

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

<uses-sdk android:minSdkVersion="10" />

<application
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name" >
</application>
<activity android:name=".pinpoint" android:label="pinpoint">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
</activity>

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

七堇年 2024-12-29 16:38:01

您的活动需要位于清单中的应用程序标记内,

<application
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name" >

<activity android:name=".pinpoint" android:label="pinpoint">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
</activity>

</application>

这与此类似:

无法启动服务意图

Your Activity needs to be inside of your application tag in your manifest

<application
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name" >

<activity android:name=".pinpoint" android:label="pinpoint">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
</activity>

</application>

It's a similar issue to this:

Unable to start Service Intent

清风挽心 2024-12-29 16:38:01

您的 标记需要位于 块中。

Your <activity> tag needs to be in the <application> block.

等风来 2024-12-29 16:38:01

您的清单是否有可能未提及任何活动?如果您安装的应用程序清单中没有任何活动,您将会遇到此行为。

Is it possible your manifest does not refer to any activities? If you install an app with no activities in the manifest you will get this behavior.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文