Tag Archives: ads

3,657 views

Ad baner without GoogleAdMobAdsSdkAndroid-6.4.1 Android example

First: AdView is in XML file <com.google.android.gms.ads.AdView xmlns:ads="http://schemas.android.com/apk/res-auto" android:id="@+id/adView" android:layout_width="match_parent" android:layout_height="wrap_content" ads:adUnitId="MY_AD_UNIT_ID" ads:adSize="BANNER"/>   // onResume AdView adView = (AdView)this.findViewById(R.id.adView); AdRequest adRequest = new AdRequest.Builder() .addTestDevice(AdRequest.DEVICE_ID_EMULATOR) .addTestDevice("TEST_DEVICE_ID") .build(); adView.loadAd(adRequest); Second: Using AdView in Fragment with LinearLayout Resolve error in ADT … Continue reading

Posted in Android Examples Code | Tagged , , , | Comments Off on Ad baner without GoogleAdMobAdsSdkAndroid-6.4.1 Android example