我是Android的新手,我试图在清单中设置installLocation
,我发现here我的minsdk应该是Ver2.2(froyo)及更高版本。
在我的主要节日中:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="ir.royalplus.guessyourcar"
android:versionCode="1"
android:installLocation="auto"
android:versionName="3.0" >
<uses-sdk android:minSdkVersion="7" android:targetSdkVersion="17" />
但是我仍然有这个错误:
error: No resource identifier found for attribute 'installLocation' in package 'android'
我的代码有什么问题?!
最佳答案
android:installLocation
是在API级别8
中引入的。由于您的minSdkVersion="7"
低于8,因此不支持。要解决此问题,请将您的minSdkVersion
设置为8或更高。
Source