【Android】- Error:The<activity>element must be a direct child of the <application> element[WrongMani]
来源:互联网 发布:域名IP是什么意思 编辑:程序博客网 时间:2024/06/04 19:57
这个问题在于我们在清单文件中把一个Activity 放到了另一个Activity中。
正常情况下是这样:
<application android:name=".app.App" android:allowBackup="true" android:icon="@mipmap/ic_app" android:label="@string/app_name" android:roundIcon="@mipmap/ic_app" android:supportsRtl="true" android:theme="@style/AppTheme">如果我们写成这样:<activity android:name=".ui.activity.FreehandActivity"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity></application>
<application android:name=".app.App" android:allowBackup="true" android:icon="@mipmap/ic_app" android:label="@string/app_name" android:roundIcon="@mipmap/ic_app" android:supportsRtl="true" android:theme="@style/AppTheme">就会出现:Error:The<activity>element must be a direct child of the <application> element[WrongMani]<activity android:name=".ui.activity.MainActivity"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter><activity android:name=".ui.activity.SecondActivity"/>
</activity></application>
阅读全文
0 0
- 【Android】- Error:The<activity>element must be a direct child of the <application> element[WrongMani]
- Word2010 Error:The name in the end tag of the element must match the element type in the start tag.
- The content of element type "configuration" must match "EMPTY". Children of type "comment" are not a
- HTML Parsing Error: Unable to modify the parent container element before the child element is closed
- HTML Parsing Error:Unable to modify the parent container element before the child element is closed
- HTML Parsing Error: Unable to modify the parent container element before the child element is closed
- VS2010:error C3083: 'Windows': the symbol to the left of a '::' must be a type
- VS2010:error C3083: 'Office': the symbol to the left of a '::' must be a type
- ibatis:The content of element type "sqlMap" must match
- The content of element type "package" must match...
- The content of element type "struts-config" must match 解决方案
- The content of element type "package" must match 。。。。。。
- The content of element type "package" must match 随笔
- The content of element type "web-app" must match "
- The content of element type "web-app" must match
- the content of element type must match解决方法
- The content of element type "tag" must match
- Main application must be in the list of application paths
- 成员变量和局部变量区别
- 聚类算法学习笔记(将持续更新)
- VC2013同一个工程生成的exe文件显示不同的图标
- 网站SEO优化之tag标签优化方法
- Cost Based Optimizer in Apache Spark 2.2
- 【Android】- Error:The<activity>element must be a direct child of the <application> element[WrongMani]
- hdu 2825 ac自动机+dp
- 插入法、选择法、冒泡法(C++实现)
- DWR第一篇之入门示例
- C#上位机通过TCP/IP完全控制YAMAHA四轴机器人开发
- 视频编解码学习之一:理论基础
- 【持续更新】Android工程师常见面试题型
- HDU 1856 more is better (简单题)
- 字符串中所有的字符是不是在长字符串中出现