I got a Problem with implementing Admob into an App.
This is my main.xml:
Above error occurs when you use the library GoogleAdMobAdsSdk-4.3.1.jar. I've been that error and I've found this demo from Google. I've replaced lib 4.3.1 by 4.0.3 in this demo and it runs OK.
if you use AndroidStudio and Gradle, you must also update the build.gradle file like this:
android {
compileSdkVersion 17
buildToolsVersion "18.0.1"
defaultConfig {
minSdkVersion 3
targetSdkVersion 17
}
...
Have you also set your build target to be higher than Android 3.2, i.e. in default.properties set target higher than android-13? Also make sure that you're using the latest version of the SDK.
PS! Don't expose your device ID to the public.
My solution to a similar case was to use
<uses-sdk
android:minSdkVersion="7"
android:targetSdkVersion="11" />
or just use android:targetSdkVersion= under 13
You also need to set the following permissions in your AndroidManifest.xml.
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
Then admob can assess the internet and also not show the ad when it has no internet connectivity.
As you can see here, very few phones have Android versions of 3.x.x or higher installed
http://developer.android.com/resources/dashboard/platform-versions.html
Why would anybody want to compile their app to something few phones can handle? Either I am misunderstanding something or I will need to find some other ad company that doesn't require a newer Android version.