About AdViews, how many can i implement? - android

I've got following problem.
I got two different Activities in my Android application. Now I wanted to add an AdView on each of these activities.
It worked for me adding one adView to "BANNER" and the other one to "SMART_BANNER".
But now, when I try to set both AdViews (the one activity and the other activity), to "SMART_BANNER", I noticed that one of these Banners won't show up.
This made me ask several questions:
How many adViews am i allowed to implement in one app?
How many adVies am i allowed to implement in one single activity?
Why doesn't it work when using two SMART_BANNER in one app? Why does it work when using one BANNER and one SMART_BANNER adView in one class?
I hope you can help me.

It is against Admob TOS for you to display 2 AdViews on the one Activity.
But it is totally acceptable to display more than one AdView within your app. But in reality you only want to display AdViews where the user spends most of their time.

Related

Log in screen before the app

Hey I am working an android app and it's basically just one activity, which is a map, but I want a Facebook login screen before they get the layout with the map. Should I make another activity specifically for the log in screen or should I make another layout and use the same activity with two layouts. Also is it generally better to always make another activity for another layouts. Also any other tips around my issue would be appreciated, since a facebook log in screen before your app is pretty common. Thanks!
For the Facebook Login Screen, here's the link I thought you'd help.
https://code.tutsplus.com/tutorials/quick-tip-add-facebook-login-to-your-android-app--cms-23837
About the layouts, in my opinion, in this situation less layouts are better to manipulate but it's still up to you.
Good Luck.
G.

Adding admob ads to an app on particular activities?

I'm a beginner in android development. The app I develop has 30 activities. I'm in the process of adding admob ads to my app. Can I add ads only to 10 of 30 activities. Is it ok to add ads to only 10 activities, is it correct. If not is there any shortcuts to add ads to all activities. Shortcut in the sense programmatically adding ads to one activity and extending it to all activities.
First thing is that there is no shortcut to add it to all activities.
For putting the ad into the activities you want, put the JAVA and XML code only in the activity you want to place the ad.
Gradle is common for the whole project.
My Personal Advice - Do more code and get the concepts more well before indulging in the Ads. They are a bit complex for beginners.

Admob integration in a single activity application with multiple fragments

I am trying to develop an application which have a single activity. I have achieved all the functionality using multiple fragments. I am showing advertisement using Admob in OnCreate of the activity.
Question:
Should I shift Admob code to OnCreate of each fragment for more impressions?
No. This might increase impressions but it not increase your revenue (revenue it a function of clicks not impressions) and may well decrease it (you may start getting lower value impressions because your CTR will drop). It will also unnecessarily complicate your code.

Admob add within multiple activities

I am trying to add Admob in my android application which consists of over 15 activities. My question is which solution is the best one, considering that I can't extend any "BaseActivity" (for various reasons), as presented in this example: Admob on Multiple Activities? and I don't want to violate any agreements regarding rules making adds requests and their use.
So far i've created a file admob.xml containing the com.admob.android.ads.AdView
and I use "include layout" in each layout ".xml" file loaded in every activity.
Is this OK? Will I have any problems with Google policies or something like that? Or will this implementation cause me losing potential revenue?
That is a reasonable solution and complies with AdMob policies. Just make sure you don't have two banners on the same page.
The Best way is to switch to fragments,
Your main application will be in the main fragment, and your ad in the Ad Fragment.
This way you can switch your previus activities with fragments, and you will need to initialize the ad Fragment only once, also this will prevent new ad request when you create a new activity (which can lower your admob RPM).
Eli

Android: Admob doesn't work on multiple pages?

I was able to setup admob in my app but it only shows in the first page where i first setup. I copied same code on different activity and layout but these never appear. Any idea why? and is it possible to display admob on different layout xml?
thanks.
I see this working in the way you describe it in other ways, so I guess it should definitely be possible to have Ads on multiple pages.
Have you tried putting your ads into test mode- do they appear by then? If not you probably have a different problem (like layout etc..)
http://developer.admob.com/wiki/Android

Categories

Resources