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

  • SEARCH
  • Home
  • 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 7624271
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T04:55:09+00:00 2026-05-31T04:55:09+00:00

I display into my android application AdMob’s banners. I would like that when the

  • 0

I display into my android application AdMob’s banners. I would like that when the user click on the banner it gone. I have try the code AdView.setOnClickListener but it not work…

EDIT : this is the code

private void visual_banner(){
//##### Pubblicità #####
        //Create the adView    
        adView = new AdView(this, AdSize.BANNER, "a14e5bed604ebf8");   
        // Lookup your LinearLayout assuming it’s been given    
        // the attribute android:id="@+id/mainLayout"    
        LinearLayout layout = (LinearLayout)findViewById(R.id.layout_ads_streaming);    
        // Add the adView to it    
        layout.addView(adView); 
        // Initiate a generic request to load it with an ad    
        adView.setOnClickListener(new OnClickListener(){

            @Override
            public void onClick(View arg0) {
                adView.destroy();
                img.setVisibility(View.VISIBLE);
            }
        });
        adView.loadAd(new AdRequest());
        //### FINE PUBBLICITA'
}
  • 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-05-31T04:55:10+00:00Added an answer on May 31, 2026 at 4:55 am

    I can help you with AdWhirl adds.

    I have seen sources and have done next:

    public class AdWhirlLayoutCustom extends AdWhirlLayout {
    
    public AdWhirlLayoutCustom(Activity context, String keyAdWhirl) {
        super(context, keyAdWhirl);
    }
    
    public AdWhirlLayoutCustom(Context context, AttributeSet attrs) {
        super(context, attrs);
    }
    
    // We intercept clicks
    @Override
    public boolean onInterceptTouchEvent(MotionEvent event) {
        boolean result = super.onInterceptTouchEvent(event);
        switch (event.getAction()) {
    
        case MotionEvent.ACTION_DOWN:
                        // Click!
            break;
        }
    
        return result;
    }
    

    }

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

Sidebar

Related Questions

I'm writing my first Android application and I have one activity that I'd like
I have a drawing application in Android that allows the user to draw with
In android phonegap application I crated canvas using html and display image in that
I am developing an android application using google maps. I have to display some
I have an android application i have been working on that downloads an image
I'm writing an Android application that needs to store dates and time into file
I currently have an Android application that displays a schedule for a ferry boat.
I am currently creating an application (iPhone/iPad/Android) that uses a map to display houses
I'm working on my first android application and running into an issue I can't
I have to do a small android application. It should connect with facebook and

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.