nullpointerexception from adview, trying to implement amazon ads in android studio /

Published at 2018-09-15 14:10:01

Home / Categories / Mobile ads / nullpointerexception from adview, trying to implement amazon ads in android studio
Hi. I am trying to include Amazon ad banners in my Android App. I am following the QuickStart Guide (https://developer.amazon.com/docs/mobile-ads/mb-rapid/fast-start.html). After setting the App Key,I initialize the adView variable:this.adView = (AdLayout) findViewById(R.id.adview);but the variable adView turns red with the warning: Cannot resolve symbolSo, guessing that the type of this adView variable is: com.amazon.device.ads.
AdLayout, and I implement instead: com.amazon.device.ads.
AdLayout adView = (AdLayout) findViewById(R.id.adview);
AdTargetingOptions adOptions =
novel AdTargetingOptions();But if I run the code,I score: NullPointerException in:this.adView.loadAd(adOptions);It seems that they have been correctly instantiated, so what am I lost here?By the way, or they recommend to include the Google Play Services SDK,but the specific Google site doesn't actually specify which libraries we should add. And adding all the Play libraries seems inconvenient. I guess that they implicitly propose to install the Play library to run Google Mobile Ads (com.google.android.gms:play-services-ads:15.0.1), right?Can you point me to a basic Android APP that actually runs Amazon banners, and so I can guesstimate what is not working with my own App? Thanks

Source: amazon.com

Warning: Unknown: write failed: No space left on device (28) in Unknown on line 0 Warning: Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/tmp) in Unknown on line 0