IOS native ad loads but doesn't show.

20 views
Skip to first unread message

Justine

unread,
Oct 14, 2024, 8:54:07 AM10/14/24
to Google Mobile Ads SDK Developers
Hi, I am testing both on my iOS simulator and iOS device. 
The native ad shows on my android device but not on my iOS devices.
The weird thing is that the banner ad loads and shows on the iOS device, just not the native ads.
The ad does load and I see this response Ad loaded.ResponseInfo(responseId: CO6JyYOSjIkDFV_t9QIdhLMSmQ, mediationAdapterClassName: GADMAdapterGoogleAdMobAds, adapterResponses: [AdapterResponseInfo(adapterClassName: GADMAdapterGoogleAdMobAds, latencyMillis: 3566, description: {
But I don't see the native ad at all. It does not show on the app at all. Here is how I am loading the ad.
void _loadNativeAd() {
String adUnitId;
if (Platform.isAndroid) {
adUnitId = 'adidforandroidhidden';
} else if (Platform.isIOS) {
adUnitId = 'adidforioshidden';
} else {
throw UnsupportedError('Unsupported platform');
}

_nativeAd = NativeAd(
adUnitId: adUnitId,
factoryId: 'adFactoryExample',
listener: NativeAdListener(
onAdLoaded: (ad) {
setState(() {
_isAdLoaded = true;
});
print('Ad loaded.${ad.responseInfo}');
},
onAdFailedToLoad: (ad, error) {
ad.dispose();
print('Ad failed to load: $error');
},
),
request: AdRequest(),
);

_nativeAd!.load();
}
"Ad Source ID" = 5450213213286189855;
"Ad Source Instance ID" = "";
"Ad Source Instance Name" = "AdMob (default)";
"Ad Source Name" = "AdMob Network";
AdUnitMapping = {
};
Latency = "3.566";
Network = GADMAdapterGoogleAdMobAds;
}, adUnitMapping: {}, adError: null, adSourceName: AdMob Network, adSourceId: 5450213213286189855, adSourceInstanceName: AdMob (default), adSourceInstanceId: )], loadedAdapterResponseInfo: AdapterResponseInfo(adapterClassName: GADMAdapterGoogleAdMobAds, latencyMillis: 3566, description: {
"Ad Source ID" = 5450213213286189855;
"Ad Source Instance ID" = "";
"Ad Source Instance Name" = "AdMob (default)";
"Ad Source Name" = "AdMob Network";
AdUnitMapping = {
};
Laten<…>
Reply all
Reply to author
Forward
0 new messages