B4A Library FirebaseAdMob - Admob ads integrated with Firebase backend

Status
Not open for further replies.

Computersmith64

Well-Known Member
Licensed User
Longtime User
Hi, reading the firebase docs, it says it could be a good idea to pre-load the interstitial ads to avoid latency. Is this possible with the B4A implementation? If not, what is your experience using interstitial ads? Do they tend to open slowly?
Yes - just call the LoadAd method. You have a couple of obvious choices there:

1) In a game, call LoadAd at a certain point in the game / level where you are pretty confident the user isn't going to restart before the end & there is enough time to load the ad before you want to show it (it can take a few seconds if the data rate is slow). This way you won't see a high Requests to Impressions ratio due to ads being loaded but then not shown.

2) If you're not worried about the Requests to Impressions ratio, just call LoadAd as soon as you've initialized your Interstitial object.

You definitely should pre-load interstitials, otherwise the user will see a significant delay when you go to show an ad - not good.

Remember that you have to call LoadAd after you have shown each interstitial, so the easiest way to do that is just call it in the AdClosed method.

- Colin.
 
Last edited:

moster67

Expert
Licensed User
Longtime User
Thanks Colin - your info clarified lots of things for me.
 

Douglas Farias

Expert
Licensed User
Longtime User
hi, @Erel
can you please change the refresh time of bannerads?
if the user dont have internet the event FailedToReceiveAd will be called later 1 min using banner ads.

B4X:
Sub BannerAd_FailedToReceiveAd (ErrorCode As String)
    csu.CallSubDelayedPlus(Me,"Recarrega_Banner",1000)
    Log("try again banner, try again every 1 sec")
End Sub

Sub Recarrega_Banner
   BannerAd.Load
End Sub

with interstitial i dont need to wait this time, if FailedToReceiveAd on interstitial i got the event fired at the same time (max 1 second), no delay.

here is some logs


many thx
 

mkvidyashankar

Active Member
Licensed User
Longtime User
i am getting this error while integrating firebase admob


manifest is as follows

how to correct this?
Thanks in advance
 
Last edited:

mkvidyashankar

Active Member
Licensed User
Longtime User
Thank you very much
it is working

In other program i followed the same procedure but getting this error

Manifest is

where i am doing error? pl help
 

catyinwong

Active Member
Licensed User
Longtime User
The following error occurs:

B4A version: 6.50
Parsing code. (0.42s)
Compiling code. (1.24s)
Compiling layouts code. (0.11s)
Organizing libraries. Error
Maven artifact not found: com.google.firebase/firebase-ads

May I ask way?
 

catyinwong

Active Member
Licensed User
Longtime User
Last edited:

catyinwong

Active Member
Licensed User
Longtime User
Which error message do you see?

"Error occurs when analysis suite" on my mobile phone when installing (might not be the exact wording since my android is in Chinese version). Nothing detected in B4A.
 

catyinwong

Active Member
Licensed User
Longtime User
Are you connected to the device in USB debug mode? If so then check the unfiltered logs. There might be more information there.

Another thing to try is to first uninstall the existing app.

Here is what listed in the unfiltered log:

Installing file.
** Activity (main) Pause, UserClosed = false **
updateVisibility : ActivityRecord{86bd645 token=android.os.BinderProxy@d622d13 {anywheresoftware.b4a.b4abridge/anywheresoftware.b4a.b4abridge.main}} show : false
** Activity (main) Resume **
Setting install_non_market_apps has moved from android.provider.Settings.Global to android.provider.Settings.Secure, returning read-only value.
Timeline: Activity_idle id: android.os.BinderProxy@d622d13 time:1110728640

And I have already tried uninstalling the previous one before I run the debug again.
 

catyinwong

Active Member
Licensed User
Longtime User
Are you connected to the device in USB debug mode? If so then check the unfiltered logs. There might be more information there.

Another thing to try is to first uninstall the existing app.

Here is what listed in the unfiltered log:

Installing file.
** Activity (main) Pause, UserClosed = false **
updateVisibility : ActivityRecord{86bd645 token=android.os.BinderProxy@d622d13 {anywheresoftware.b4a.b4abridge/anywheresoftware.b4a.b4abridge.main}} show : false
** Activity (main) Resume **
Setting install_non_market_apps has moved from android.provider.Settings.Global to android.provider.Settings.Secure, returning read-only value.
Timeline: Activity_idle id: android.os.BinderProxy@d622d13 time:1110728640

And I have already tried uninstalling the previous one before I run the debug again.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…