I'm trying to add Admob banner on my Windows Phone 8.1 app, I've done everything same with Google's documentation and When I run it on emulator, it works perfectly. I see test ads and normal ads on screen, but when I run it on real device (Lumia 920) it fails and OnFailedToReceivedAd works and gives me NoFill as errorcode. I'm searching over 2 days on internet. Please help me. My codes below from MainPage.xaml.cs
AdView bannerAd = new AdView
{
Format = AdFormats.Banner,
AdUnitID = "ca-app-pub-4629040566186464/6355149637"
};
bannerAd.ReceivedAd += OnAdReceived;
bannerAd.FailedToReceiveAd += OnFailedToReceiveAd;
DrawingSurfaceBackground.Children.Add(bannerAd);
AdRequest adRequest = new AdRequest();
// adRequest.ForceTesting = true;
bannerAd.LoadAd(adRequest);
}
private void OnAdReceived(object sender, AdEventArgs e)
{
Debug.WriteLine("Received ad succesfully");
txtas.Text = "Received ad succesfully";
}
private void OnFailedToReceiveAd(object sender, AdErrorEventArgs errorCode)
{
Debug.WriteLine("Received ad unsuccesfull"+errorCode.ErrorCode);
txtas.Text = "Received ad unsuccesfull";
}**
I made this app on Unity3d, Because of Google Admob SDK doesn't support Windows Phone, so I've done steps on this website http://gamedevtodied.blogspot.com.tr/2015/06/unity3d-how-to-integrate-admob-for.html. As I said it works on emulator but not working on device.