If you encounter this problem:

Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Lcom/google/ads/AdRequest$ErrorCode;

Chances are you just included the Google Play Services library together with your Google AdMob library.

Since Google AdMob is already part of the Google Play Services library, just remove it. Your ads just be back up in no time.

There is no method to automatically change your Android app’s container size for showing Google AdMob ads. While it does re-adjust itself whenever the orientation changes, it does not resize itself to the correct size.

Try changing your device’s orientation from portrait to landscape mode and you will see that the height is the same. The result is that the height of the ad container shown is too big just like when its orientation is in portrait mode.

The workaround to make the ad container resize correctly according to orientation change like the image below is to remove the ad container in your layout view and add it back.

ad_orientation

Say this is your code for adding the ad container view to your layout view.

Then place the method in the onConfigurationChanged().

Related Posts Plugin for WordPress, Blogger...