Error:(13) Error: The <receiver>元素必须是 <application> 的直接子元素.元素 [WrongManifestParent] 是什么意思,我该如何解决? [英] What does Error:(13) Error: The <receiver> element must be a direct child of the <application> element [WrongManifestParent] mean and how do i fix it?

查看:48
本文介绍了Error:(13) Error: The <receiver>元素必须是 <application> 的直接子元素.元素 [WrongManifestParent] 是什么意思,我该如何解决?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在尝试编译我的应用程序时遇到问题,我尝试从拨号器启动它,并且清单文件收到此错误.这是我的清单文件

Im having problems when trying to compile my app, im trying to launch it from the dialler and the manifest file gets this error. Here is my manifest file

<uses-permission android:name="android.permission.PROCESS_OUTGOING_CALLS"/>
<application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".MainActivity"
        android:label="@string/app_name" >
        <receiver
            android:name=".receiver.DialReceiver"
            android:exported="true"

            android:process=":background"
            >
            <intent-filter>
                <action android:name="android.intent.action.NEW_OUTGOING_CALL" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
        </receiver>
    </activity>
</application>

推荐答案

移动

 <receiver
        android:name=".receiver.DialReceiver"
        android:exported="true"

        android:process=":background"
        >
        <intent-filter>
            <action android:name="android.intent.action.NEW_OUTGOING_CALL" />
            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </receiver>

外部 标签

这篇关于Error:(13) Error: The &lt;receiver&gt;元素必须是 &lt;application&gt; 的直接子元素.元素 [WrongManifestParent] 是什么意思,我该如何解决?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆