3

I am trying to run test ads on my app but I am always getting this error

06-14 19:42:04.223 7573-7573/com.pk.kapp I/Ads: Starting ad request.
06-14 19:42:08.757 7573-8262/com.pk.kapp I/Ads: Trying mediation network: 
06-14 19:42:08.767 7573-7573/com.pk.kapp I/Ads: Instantiating mediation adapter: com.google.DummyAdapter
06-14 19:42:08.767 7573-8262/com.pk.kapp I/Ads: No fill from any mediation ad networks.
06-14 19:42:08.777 7573-7573/com.pk.kapp W/Ads: Failed to load ad: 3

I am doing this in the onCreate of my fragment:

@Override
public void onCreate(Bundle savedInstanceState)
{
    Log.d(TAG, "onCreate");
    super.onCreate(savedInstanceState);

    mInterstitialAd = new InterstitialAd(getActivity());
    mInterstitialAd.setAdUnitId("ca-app-pub-3940256099942544/1033173712");
    AdRequest adRequest = new AdRequest.Builder()
            .build();
    mInterstitialAd.loadAd(adRequest);
    mInterstitialAd.setAdListener(new AdListener() {
        @Override
        public void onAdClosed() {
            pageContent.setVisibility(View.VISIBLE);
        }

        @Override
        public void onAdFailedToLoad(int i) {
            Log.d(TAG, "Ad failed to loadvand error code is " + i);
        }

        @Override
        public void onAdLeftApplication() {
        }

        @Override
        public void onAdOpened() {
        }

        @Override
        public void onAdLoaded() {
            Log.d(TAG, "Ad has has loaded to load");
        }
    });
}

Please, is there any solution to this? Like what is causing it and how it can be resolved.

X09
  • 3,827
  • 10
  • 47
  • 92

0 Answers0