אם טעינת המודעה נכשלת, מופעלת קריאה חוזרת של כשל שמספקת אובייקט LoadAdError.
קטע הקוד הבא מאחזר מידע על שגיאות כשמודעה מתגמלת לא נטענת:
onAdFailedToLoad:(ad,loadAdError){// Gets the domain from which the error came.Stringdomain=loadAdError.domain;// Gets the error code. See// https://developers.google.com/admob/android/reference/com/google/android/gms/ads/AdRequest// and https://developers.google.com/admob/ios/api/reference/Enums/GADErrorCode// for a list of possible codes.intcode=loadAdError.code;// A log friendly string summarizing the error.Stringmessage=loadAdError.message;// Get response information, which may include results of mediation requests.ResponseInfo?responseInfo=loadAdError.responseInfo;}
המידע הזה יכול לשמש כדי לקבוע בצורה מדויקת יותר מה גרם לטעינת המודעה להיכשל. בפרט, אם מופיעות שגיאות בדומיין com.google.admob ב-iOS או com.google.android.gms.ads ב-Android, אפשר לעיין במאמר הזה במרכז העזרה כדי לקבל הסבר מפורט יותר על השגיאות ועל הפעולות שאפשר לבצע כדי לפתור את הבעיה.GetMessage()
[[["התוכן קל להבנה","easyToUnderstand","thumb-up"],["התוכן עזר לי לפתור בעיה","solvedMyProblem","thumb-up"],["סיבה אחרת","otherUp","thumb-up"]],[["חסרים לי מידע או פרטים","missingTheInformationINeed","thumb-down"],["התוכן מורכב מדי או עם יותר מדי שלבים","tooComplicatedTooManySteps","thumb-down"],["התוכן לא עדכני","outOfDate","thumb-down"],["בעיה בתרגום","translationIssue","thumb-down"],["בעיה בדוגמאות/בקוד","samplesCodeIssue","thumb-down"],["סיבה אחרת","otherDown","thumb-down"]],["עדכון אחרון: 2026-07-08 (שעון UTC)."],[],["When an ad fails to load, a `LoadAdError` object is provided via a callback. This object contains error details, including the error's domain, a specific error code, a summarized message, and response information that could be related to mediation. For errors originating from `com.google.admob` (iOS) or `com.google.android.gms.ads` (Android), the message can be checked in a help center article for in-depth information and potential solutions. This information helps to pinpoint the cause of ad loading failure.\n"]]