Stay organized with collections
Save and categorize content based on your preferences.
GoogleMobileAds.
Api.
AdError
Error information about why an ad operation failed.
Summary
Inheritance
Direct Known Subclasses: GoogleMobileAds.Api.AdInspectorError
, GoogleMobileAds.Api.LoadAdError
Constructors and Destructors
Returns the cause of this error or null
if the cause is nonexistent or unknown.
int
Returns the error code.
string
Return "MobileAds" for Google Mobile Ads SDK errors, or a domain defined by mediation networks for mediation errors.
string
Returns the error message.
override string
Returns a log friendly string version of this object.
Public functions
AdError
AdError
(
IAdErrorClient
client
)
Creates a AdError
.
Parameters
client
A platform level IAdErrorClient implementation.
GetCause
AdError
GetCause
()
Returns the cause of this error or null
if the cause is nonexistent or unknown.
GetDomain
string
GetDomain
()
Return "MobileAds" for Google Mobile Ads SDK errors, or a domain defined by mediation networks for mediation errors.
GetMessage
string
GetMessage
()
ToString
override
string
ToString
()
Returns a log friendly string version of this object.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-04-22 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2026-04-22 UTC."],[],["`AdError` provides details on ad operation failures. It has subclasses like `AdInspectorError` and `LoadAdError`. Key actions include: creating an `AdError` with an `IAdErrorClient`, retrieving error details like the code (`GetCode`), domain (`GetDomain`), message (`GetMessage`), and cause (`GetCause`), also can return a log-friendly string version of this object using (`ToString`). The domain indicates if the error is from Google Mobile Ads or a mediation network.\n"]]