I am trying to insert ads into my (not yet published) app. All I am doing right now is printing the result of the ads.show to a label named “rsltAd” that is in the position I would like my ad to show up.
When I run the app on my test iPhone6, I get a runtime error that says "Could not load provider (admob) : module “CoronaProvider.ads.admob” not found (and a lot of other error details).
I am thinking maybe my “appId” variable should be the actual “name” of the app, not the Publisher ID that I got from admob when I created my admob account? But this also results in a very similar error message.
During initialization, I execute the following:
local ads = require (“ads”)
local adCount = 0
local appId = “pub-415hugenumber787” – which is really a 16-digit number that is my admob “Publisher ID”
OK, did the Monetize step and got an appID that conforms to the pattern you showed. However, still get pretty much same result.
Runtime error ERROR: could not load provider (admob) due to: module ‘CoronaProvider.ads.admob’ not found resource (CoronaProvider.ads.admob.lu) does not exist in archive no field package.preload[‘CoronaProvider.ads.admob’] no file ‘/private/var/mobile/Containers/bundle/Application/and so forth and so on’
Well, I thought I did, but I had put the plugin code into the wrong build.settings file (i.e., for a different app in a different folder). By the way, this is something that bugs the heck out of me about Sublime Text 2 – I have had this happen more than once.)
The main thing is: now that I have the build.settings straightened out, I get this:
Feb 25 05:25:52.065: ERROR: Builder failed: Undefined symbols for architecture armv7:
Feb 25 05:25:52.065: BUILD ERROR: There was a problem linking the app.
Check the console for more information.
Feb 25 05:25:52.065: “_OBJC_CLASS_$_ASIdentifierManager”, referenced from:
Feb 25 05:25:52.065: objc-class-ref in libads-admob.a(GADDevice.o)
Feb 25 05:25:52.065: objc-class-ref in libads-admob.a(GADGestureIdUtil.o)
Feb 25 05:25:52.065: ld: symbol(s) not found for architecture armv7
Feb 25 05:25:52.065: clang: error: linker command failed with exit code 1 (use -v to see invocation)
OK, did the Monetize step and got an appID that conforms to the pattern you showed. However, still get pretty much same result.
Runtime error ERROR: could not load provider (admob) due to: module ‘CoronaProvider.ads.admob’ not found resource (CoronaProvider.ads.admob.lu) does not exist in archive no field package.preload[‘CoronaProvider.ads.admob’] no file ‘/private/var/mobile/Containers/bundle/Application/and so forth and so on’
Well, I thought I did, but I had put the plugin code into the wrong build.settings file (i.e., for a different app in a different folder). By the way, this is something that bugs the heck out of me about Sublime Text 2 – I have had this happen more than once.)
The main thing is: now that I have the build.settings straightened out, I get this:
Feb 25 05:25:52.065: ERROR: Builder failed: Undefined symbols for architecture armv7:
Feb 25 05:25:52.065: BUILD ERROR: There was a problem linking the app.
Check the console for more information.
Feb 25 05:25:52.065: “_OBJC_CLASS_$_ASIdentifierManager”, referenced from:
Feb 25 05:25:52.065: objc-class-ref in libads-admob.a(GADDevice.o)
Feb 25 05:25:52.065: objc-class-ref in libads-admob.a(GADGestureIdUtil.o)
Feb 25 05:25:52.065: ld: symbol(s) not found for architecture armv7
Feb 25 05:25:52.065: clang: error: linker command failed with exit code 1 (use -v to see invocation)