Stay organized with collections
Save and categorize content based on your preferences.
GoogleMobileAds.Api.AdManager.AdManagerBannerView
Banner view that works with Google Ad Manager.
Summary
Banner views occupy a spot within an app's layout. They stay on screen while users are interacting with the app.
Inheritance
Inherits from:
GoogleMobileAds.Api.BannerView
Properties
|
ValidAdSizes
|
Sets the supported sizes of the banner ad.
|
Events
OnAppEventReceived
Action< AppEvent > OnAppEventReceived
Raised when the app receives an event from the banner ad.
Properties
ValidAdSizes
List< AdSize > ValidAdSizes
Sets the supported sizes of the banner ad.
In most cases, only one ad size will be specified. Use one of the predefined standard ad sizes (such as AdSize.MediumRectangle), or create one by specifying width and height.
Multiple ad sizes can be specified if your application can appropriately handle multiple ad sizes. For example, your application might read ValidAdSizes during the AdManagerBannerView::OnBannerAdLoaded callback and change the layout according to the size of the ad that was loaded. If multiple ad sizes are specified, the AdManagerBannerView will assume the size of the first ad size until an ad is loaded.
This method also immediately resizes the currently displayed ad, so calling this method after an ad has been loaded is not recommended unless you know for certain that the content of the ad will render correctly in the new ad size. This can be used if an ad needs to be resized after it has been loaded. If more than one ad size is specified, the currently displayed ad will be resized to the first ad size.
Public functions
AdManagerBannerView
AdManagerBannerView(
string adUnitId,
AdSize adSize,
AdPosition position
)
Creates an Ad Manager banner view with a standard position.
AdManagerBannerView
AdManagerBannerView(
string adUnitId,
AdSize adSize,
int x,
int y
)
Creates an Ad Manager banner view with a custom position.
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 2023-09-07 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"Missing the information I need"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"Too complicated / too many steps"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"Out of date"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"Samples / code issue"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
{"lastModified": "Last updated 2023-09-07 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 2023-09-07 UTC."]]