Android Question Screen resolution differs with admob

deyan666

Member
Licensed User
Longtime User
I hope the title can make sense. Basically I have an app released and on Samsung there screen setup is perfect with admob but I find with HTC the screen doesn't fill like it's suppose to. I find the admob banner at the bottom covers the interface and the interface is lower than it should be. Any idea how to fix this issue? Current setup:


B4X:
     Private heightad As Int
     adbox.Initialize2("Ad", "ca-app-pub-85089637014xxxxxxxxxxxxx5913" , adbox.SIZE_SMART_BANNER )
    If GetDeviceLayoutValues.ApproximateScreenSize < 6 Then
      If 100%x > 100%y Then heightad = 32dip Else heightad = 50dip
    Else
    heightad = 90dip
    End If
    Activity.AddView(adbox, 0dip, 100%y - heightad, 100%x, heightad)
    adbox.LoadAd
    adbox.BringToFront

Should I just add "dip" at the end of all common properties for the different Views?
 
Last edited:

deyan666

Member
Licensed User
Longtime User
You should make sure that your layout leaves enough space for the ad. It will not happen automatically.
On my phone the layout has space for the ad. Although on some other devices such as HTC one it doesn't
 
Upvote 0
Top