Latest Update: Add AdMob with Google Play Service
Last time, I released a post for “Add Google Admob in Android Application“. And I got a feedback today about this admob android tutorial. The example code and that demo application doesn’t work any more. Then I checked my Admob account and found out that app’s Status is red, which mean my app is inactive. If the app works well, the status color should be green. And some of my apps status also show green color with exclamation mark, which means my app is idle (Your site was previously active but has not sent an ad request in the previous 72 hours).

Why My Admob APP Status is Inactive?

admob status
Admob Status Example

Currently, I only met this admob inactive problem twice. The first time is when I created a new app in the Admob. And this is the second time. Some friends ask me that they create a new Admob app. They can see the ads in the Android emulator with that publish id. And the app can also shows ads in their test phone as well. But in the Admob report, the status is still red (inactive). I think this is because that you might call adRequestset.Testing(true) or adRequestset.setTestDevices(“textdevice”) in your apps. And the admob also takes time to update their status. So for new app in Admob, you don’t need to worry if your app can show the ads 🙂

But my problem is here. My app worked well before. And I published it on my site to provide people to download and test. And it suddenly became inactive and the app also didn’t show the app. I didn’t get any notification about  it and there is no farther information to let me know what happened there. So I guess the reason is that I also provide the source code downloading and I remain my publish id in the source code by mistake. Many friends downloaded my source code and tried it. This may cause some invalid clicks which may violet Google policy. And eventually my publish id in admob become inactive.

Add Google Admob in Android Application With SDK 4.3.1

Since I used Admob SDK 4.0.4 in my previous example, and it is not recommended for current Admob. And that example also doesn’t work for the latest android sdk r18 and adt 18. So I will post the latest example to show you how to add Google Admob in Android application with Admob SDK 4.3.1 and Android SDK r18. For the code example, you can check source code in Admob Offical Site Tutorial. Here I will tell you why it doesn’t work when you follow that instructions.

Could not find class ‘’ Error

After you update the Android SDK to r17 or r18 and it will force you to update the ADT plugin for Eclipse to ADT 17.0.0 or ADT 18.0.0. With these update, you will meet several problems:

Adview can not be resolved to a type
Adrequest can not be resolved to a type
Adview can not be resolved to a variable

The solution for this problem is create a folder “libs” under your project, and moving your Admob SDK jar to “libs” folder.


Will Admob SDK 4.3.1 work in Android 2.3 (less than Android v3.2 or android-13)

Yes. It will. The Admob SDK 4.3.1 for Android requires you to compile your Android application against at least Android v3.2. If you want to make your application to be compatible to lower version, Android 2.3 or Android 2.2 for example. You can just set your android:minSdkVersion to 9 or 8 in your AndroidManifest.xml file. Here is the example:

<uses-sdk android:minSdkVersion="8" android:targetSdkVersion="13"/>

Download Example APK File
Download Source Code

Previous PostNext Post


      1. Hi i created app from appsgeyser and i am unble to activate it, you have any option to do it, Help Needed please , Thank you.

        1. Hi pradeep,

          I have checked AppsGeyser service, I think it is very hard to add AdMob in your App. I don’t know what’s the result of AppsGeyser output. But I think it help help you handle the Ads part. It says “Once your App reaches a required minimum usage, this advertising space will be shared with you.”


          “For Apps with less than 100 installs there is no banner space available and no ads displayed.”

          If you find that your admob ad banner is still inactive, please check your app first.

          But I still suggest you to use AdMob with native Apps.


  1. I experienced that,,, i need help,,, if you please you can check my admob .. I will send you email me with AdMob passwordna,, please help

    1. Hi, Max

      • First, when did you create your application in AdMob?
      • Second, did you try to request AdMob Ads by this applicatioiin id?
      • Third, your admob application will become active only after there are enough ads request, according to my experience.


        1. Please check this post. I hope it will help you. You can download the source code here.


  2. Pls I creat an app on AppsGeyser but istead of showing me the admob html link it’s showing like test as I paste it..

Leave a Reply

Your email address will not be published. Required fields are marked *