Android新建项目报错android:icon="@drawable/ic_launcher"
16lz
2021-01-23
Eclipse下创建了一个安卓应用
结果
/Users/123/Documents/workspace/Demo1/AndroidManifest.xml.:11: error: Error: No resource found that matches the given name (at 'icon' with value '@drawable/ic_launcher').
说是改地址下没有匹配的引用名称。
报错
AndroidManifest.xml:11: error: Error: No resource found that matches the given name (at 'icon' with value '@drawable/ic_launcher')
错误发生在
AndroidManifest.xml
中的
android:icon="@drawable/ic_launcher"
经查drawable文件夹下确实没有ic_launcher。
在minpmap文件夹下有ic_launcher。
看了网上许多网友反映的问题,应该是SDK升级之后出现的问题,估计是更改了原有的存放位置。
只要将代码
android:icon="@drawable/ic_launcher"
改为
android:icon="@mipmap/ic_launcher"
问题即可解决。
更多相关文章
- Android国际化资源 文件夹命名规范
- Android在MTP模式下,只显示指定文件夹
- android2.2资源文件详解4--menu文件夹下的菜单定义
- Android学习笔记(11)————Android的私人文件夹的文件读写操作
- android java复制和压缩文件或文件夹
- Android创建文件夹及文件并写入数据
- 读取android根目录下的文件或文件夹
- Android native/C/C++ 监控文件夹变化