31

Here is my manifest file which shows error string types not allowed at android:configChanges please help me in rectification of the error. below is my manifest file.

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

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

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

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity android:name="com.google.ads.AdActivity"
                  android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>


    </application>

    <uses-permission android:name="android.permission.INTERNET"/>
  <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>


</manifest>
Farman Khan
  • 393
  • 1
  • 6
  • 14

2 Answers2

58
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"

screenSize & smallestScreenSize attributes are not available in SDK 10.They are been introduced in API level 13.

http://developer.android.com/guide/topics/manifest/activity-element.html#config

Community
  • 1
  • 1
Vipul
  • 27,808
  • 7
  • 60
  • 75
  • 3
    IE, change project target to API level 13 or above. – amit Jan 21 '13 at 06:29
  • 2
    Project > Properties > Android > Change 'Project Build Target' to above 3.2. – Jinbom Heo Feb 14 '14 at 00:25
  • 2
    But... that means my app will not work in Gingerbread, right?:-( – yukatta Mar 08 '14 at 22:52
  • This does not mean you will loose compatibility with gingerbread @Yavierre. Target SDK is just the compiler that runs on your code. The "minimum SDK level" is the furtherest back your app will be compatible with. – Diederik Nov 20 '15 at 14:26
6
  • Make sure you have the latest copy of the Android SDK and that you're compiling against at least Android v3.2 (set target in project.properties to android-13).
  • The Google Mobile Ads SDK for Android requires a run-time of Android 2.3 or later (set android:minSdkVersion to at least 9 in your AndroidManifest.xml). This means you can develop with the latest version of the Android SDK and your app will still run on an earlier Android version (2.3 minimum).
Ameya Pandilwar
  • 2,638
  • 28
  • 28