Hi,
I got error when using iAdMob to display Banner Ad, This is the code what i use:
the code in Application_Start :
Note : I replaced the real numbers with stars.
This is the error message :
And i want to mention that i copied the GoogleMobileAdsSdkiOS-7.44.0 to the builder lib folder.
What should I do to make it work correctly?
Thank you.
I got error when using iAdMob to display Banner Ad, This is the code what i use:
the code in Application_Start :
B4X:
AdView1.Initialize("AdView1","ca-app-pub-**************~**********",FrmMain,AdView1.SIZE_BANNER)
AdView1.SetTestDevices(Array("******************************"))
AdView1.LoadAd
AdView1.Alpha = 1
AdView1.Visible = True
AdView1.BringToFront
FrmMain.RootPanel.AddView(AdView1, 0, 100%y - 50dip, 100%x, 50dip)
Note : I replaced the real numbers with stars.
This is the error message :
Application_Start
Error occurred on line: 111 (Main)
The Google Mobile Ads SDK was initialized incorrectly. Google AdMob publishers should follow instructions here: https://googlemobileadssdk.page.link/admob-ios-update-plist to include the AppMeasurement framework, set the -ObjC linker flag, and set GADApplicationIdentifier with a valid App ID. Google Ad Manager publishers should follow instructions here: https://googlemobileadssdk.page.link/ad-manager-ios-update-plist
Stack Trace: (
CoreFoundation <redacted> + 252
libobjc.A.dylib objc_exception_throw + 56
CoreFoundation <redacted> + 0
result GADVerifyApplicationID + 152
result GADVerifyApplicationID + 3172
result GADVerifyApplicationID + 4172
result GADDispatchAsyncSafeMainQueue + 56
result GADVerifyApplicationID + 4116
result GAD_GADAdSource_arm64_7_44_0 + 1832
result GAD_GADInternalBannerView_arm64_7_44_0 + 9156
result GAD_GADInternalBannerView_arm64_7_44_0 + 5728
result GADDispatchAsyncSafeMainQueue + 56
result GAD_GADInternalBannerView_arm64_7_44_0 + 4956
result GAD_GADInternalBannerView_arm64_7_44_0 + 6324
result GAD_GADBannerView_arm64_7_44_0 + 3984
result -[B4IAdView LoadAd] + 236
CoreFoundation <redacted> + 144
CoreFoundation <redacted> + 284
result +[B4I runDynamicMethod:method:throwErrorIfMissing:args:] + 1624
result -[B4IShell runVoidMethod] + 232
result -[B4IShell raiseEventImpl:method:args::] + 1792
result -[B4IShellBI raiseEvent:eventarams:] + 1372
result __33-[B4I raiseUIEvent:eventarams:]_block_invoke + 60
libdispatch.dylib <redacted> + 24
libdispatch.dylib <redacted> + 16
libdispatch.dylib <redacted> + 1012
CoreFoundation <redacted> + 12
CoreFoundation <redacted> + 2272
CoreFoundation CFRunLoopRunSpecific + 552
GraphicsServices GSEventRunModal + 100
UIKit UIApplicationMain + 236
result main + 124
libdyld.dylib <redacted> + 4
)
Application_Active
And i want to mention that i copied the GoogleMobileAdsSdkiOS-7.44.0 to the builder lib folder.
What should I do to make it work correctly?
Thank you.