Show Sidebar

Requesting Banner Ads – iOS SDK

ขออภัยรายการนี้จะใช้ได้เฉพาะในภาษาอังกฤษ English. For the sake of viewer convenience, the content is shown below in the alternative language. You may click the link to switch the active language.

Supported Banner Sizes

WxH(Size) Description Availability
320×50 Standard Banner Phones
728×90 IAB Leaderboard Tablets

The SDK will automatically request the ad-size based on the user’s device.There isn’t a need for the developer to pass ad-size explicitly during integration.

To request a banner

Create an instance of the VMaxAdView for Banner Ads and conform to the delegate.

Creating the Ad View

Objective CSwift

Set the frame of the AdView

Set the Frame for VMaxAdView prior to calling any methods of VMaxAdSDK in order to display ads properly. For a typical 320×50 ad placed at the bottom of the view, the code is as follows:

Objective CSwift

[Optional] Setting Custom Refresh Rate

Set an Ad Refresh rate greater than the default of 30 seconds.
Note 1: The minimum Ad Refresh rate is 30 seconds; setting a lower value will default to 30 seconds.
Note 2: Refresh rate is valid for Banner Ads only; Billboard Ads are not supported

Objective CSwift

Request Banner ad using cache + show API

Objective CSwift

On caching success, onAdReady delegate is triggered after which developer is expected to call showAd.

Objective CSwift

Request Banner ad using managed show API

Objective CSwift

Knowing Ad States

Usage of Ad States :

Objective CSwift

What would you like to do next?