Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8667519
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T17:58:58+00:00 2026-06-12T17:58:58+00:00

i have tried adding the com.google.ads.AdView to the xml part, xml coding as follows:

  • 0

i have tried adding the com.google.ads.AdView to the xml part, xml coding as follows:

<TableLayout 
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:ads="http://schemas.android.com/apk/lib/com.google.ads"
    android:id="@+id/tableLayout"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/background_color"
    android:gravity="center_horizontal"
    android:orientation="vertical"
    android:padding="5dp"
    android:stretchColumns="*" >
<TableRow
    <Button android:id="@+id/equal" 
        style="@style/Eq_button_style"
        android:text="=">   
    </Button>
</TableRow>

  <com.google.ads.AdView 
      android:id="@+id/adView"                         
      android:layout_width="wrap_content"                         
      android:layout_height="wrap_content"                         
      ads:adUnitId="a123123123123c"      //this ID is confirmed correct                   
      ads:adSize="BANNER"                         
      ads:testDevices="TEST_EMULATOR, xxxxxxxxxxxxxxxxx"   //this ID is confirmed correct                      
      ads:loadAdOnCreate="true"/>

</TableLayout>

However, even though the app does not crash when it runs, there is no ads showing at the bottom. the logcat is as follows:

10-10 01:45:16.360: I/GATE(16797): <GATE-M>DEV_ACTION_COMPLETED</GATE-M>
10-10 01:45:16.365: D/webviewglue(16797): nativeDestroy view: 0x3ef6f0
10-10 01:45:16.365: E/Ads(16797): An error occurred while destroying an AdWebView:
10-10 01:45:16.365: E/Ads(16797): java.lang.NullPointerException
10-10 01:45:16.365: E/Ads(16797):   at android.webkit.WebView.setWebViewClient(WebView.java:5168)
10-10 01:45:16.365: E/Ads(16797):   at com.google.ads.internal.AdWebView.destroy(SourceFile:252)
10-10 01:45:16.365: E/Ads(16797):   at com.google.ads.internal.c$e.run(SourceFile:191)
10-10 01:45:16.365: E/Ads(16797):   at android.os.Handler.handleCallback(Handler.java:605)
10-10 01:45:16.365: E/Ads(16797):   at android.os.Handler.dispatchMessage(Handler.java:92)
10-10 01:45:16.365: E/Ads(16797):   at android.os.Looper.loop(Looper.java:137)
10-10 01:45:16.365: E/Ads(16797):   at android.app.ActivityThread.main(ActivityThread.java:4511)
10-10 01:45:16.365: E/Ads(16797):   at java.lang.reflect.Method.invokeNative(Native Method)
10-10 01:45:16.365: E/Ads(16797):   at java.lang.reflect.Method.invoke(Method.java:511)
10-10 01:45:16.365: E/Ads(16797):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:980)
10-10 01:45:16.365: E/Ads(16797):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:747)
10-10 01:45:16.365: E/Ads(16797):   at dalvik.system.NativeStart.main(Native Method)
10-10 01:45:16.365: I/Ads(16797): onReceiveAd()
10-10 01:45:16.460: D/dalvikvm(16797): GC_CONCURRENT freed 424K, 6% free 9580K/10119K, paused 2ms+11ms
10-10 01:45:16.460: W/Ads(16797): Not enough space to show ad! Wants: <480, 75>, Has: <464, 708>

How can it be solved? The program does not force close, it can still execute but the ad just cannot show.
Also, the last row Logcat says not enough space? how to add more space for it? i have already reserved many space for it.

Many thanks in advance!

revised logcat:

The app can still be executed appearing without any error, but these “E” parts are there any effects on the proper execution of the app in some situation?

10-11 00:52:30.330: E/Ads(10023): An error occurred while destroying an AdWebView:
10-11 00:52:30.330: E/Ads(10023): java.lang.NullPointerException
10-11 00:52:30.330: E/Ads(10023):   at android.webkit.WebView.setWebViewClient(WebView.java:5168)
10-11 00:52:30.330: E/Ads(10023):   at com.google.ads.internal.AdWebView.destroy(SourceFile:252)
10-11 00:52:30.330: E/Ads(10023):   at com.google.ads.internal.c$e.run(SourceFile:191)
10-11 00:52:30.330: E/Ads(10023):   at android.os.Handler.handleCallback(Handler.java:605)
10-11 00:52:30.330: E/Ads(10023):   at android.os.Handler.dispatchMessage(Handler.java:92)
10-11 00:52:30.330: E/Ads(10023):   at android.os.Looper.loop(Looper.java:137)
10-11 00:52:30.330: E/Ads(10023):   at android.app.ActivityThread.main(ActivityThread.java:4511)
10-11 00:52:30.330: E/Ads(10023):   at java.lang.reflect.Method.invokeNative(Native Method)
10-11 00:52:30.330: E/Ads(10023):   at java.lang.reflect.Method.invoke(Method.java:511)
10-11 00:52:30.330: E/Ads(10023):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:980)
10-11 00:52:30.330: E/Ads(10023):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:747)
10-11 00:52:30.330: E/Ads(10023):   at dalvik.system.NativeStart.main(Native Method)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T17:59:00+00:00Added an answer on June 12, 2026 at 5:59 pm

    The issue is indeed:

    W/Ads(16797): Not enough space to show ad! Wants: <480, 75>, Has: <464, 708>
    

    For that device, you’ll need the entire width of the screen to show an ad in portrait. Part of the problem is the android:padding="5dp" on your TableLayout.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I tried adding a sliderbar using http://code.google.com/p/gwt-slider-bar/ code to a TabLayoutPanel but the sliderbar
I'm adding Android C2DM to a Android library project. I started with the com.google.android.c2dm
I have just tried adding a WebService (asmx based) from a WebForms project to
I have a root view controller with no nib file, I tried adding this
I'm adding Google Oauth2 to a Rails app, but have been unable to get
I referenced this website: http://biega.com/special-char.html to aid me in adding special characters in my
http://code.google.com/p/tesseractdotnet/ I am having a problem getting Tesseract to work in my Visual Studio
I have been reading Google's android tutorial and I got a problem... In the
I have this triple dropdown which works great from http://roshanbh.com.np/2008/01/populate-triple-drop-down-list-change-options-value-from-database-using-ajax-and-php.html Is it possible to
Currently I have a loop that tries to find an unused filename by adding

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.