Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
  • Overview of Ad control
  • Creating an Ad control
  • To create an Ad control:
  • Size of ads
  • Operating mode of Ad control
  • Test mode
  • Loading and refreshing the ads
  • Click on an ad
  • Modifying the permissions
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Stored procedures
Overview of Ad control
The Ad control is used to monetize an Android application by displaying an ad banner. This banner will generate incomes according to the number of clicks performed by the application users.
The "AdMob" protocol (Google) is used to display the ads.
  • The use of the Ad control is subject to specific terms and conditions. For more details, see the Conditions for using the Ad control help page.
  • To use an Ad control, the application must be compiled with Android SDK version 3.2 or later.
    However, the application can operate on devices running an earlier version (1.5, 1.6, 2.0, ...) in accordance with the minimum runtime version specified in the wizard for generating the Android application.
Creating an Ad control

To create an Ad control:

  1. On the "Creation" pane, in the "Graphic controls" group, click "Ad".
  2. Click at the desired location to create the control.
To view the control characteristics, select "Description" in the popup menu of the control.

Size of ads

The popup menu found on the right of the icon for control creation proposes four possible sizes:
  • 320 x 50, for the phones and tablets.
  • 300 x 250, for the tablets only.
  • 468 x 60, for the tablets only.
  • 768 x 90, for the tablets only.
  • The selected size will be the minimum size of control. The control can be enlarged in edit or at run time. In this case, the banner will remain centered in the control.
  • No ad will be display if the size of the Ad control is not sufficient.
Operating mode of Ad control

Test mode

AdMob does not allow the application provider to click his own ads or to artificially increase the number of ad displays.
The test mode of Ad control is used to display "fake ads" on which the click triggers no income.
The test mode is automatically:
  • enabled when the application is started on the emulator.
  • disabled at run time on the phone or on the tablet.
  • At run time in the simulator, the Ad control will display a fixed image whose size is identical to the size of the ad banner.
  • TestMode is used to find out whether the test mode is enabled or not.

Loading and refreshing the ads

An ad is automatically loaded in the Ad control when the window is opened.
Then, new ads can be regularly loaded in the control according to the refresh rate defined in the application setting on the AdMob site.
The ads are loaded in background task from Internet. Therefore, the device must be connected in order for the ads to be displayed. A time-out (few seconds to several minutes) may be required between the opening of the window and the actual display of the first ad. This timeout depends on the connection quality and on the ad size.
We recommend that you use the events "Loading an ad" and "Error while loading an ad" to check the display of ads in the control. For more details, see Events associated with the Ad control.
Remark: To find out whether an ad is displayed in the control, use AdLoaded.

Click on an ad

The consequences of a click performed on an ad displayed in the Ad control depend on the type of ad. The most common actions are :
  • Opening the market to download the application corresponding to the ad.
  • Opening the browser on the site corresponding to the ad.
Modifying the permissions
Using an Ad control automatically adds the following permissions to the list of permissions required by the application:
Minimum version required
  • Version 17
Click [Add] to post a comment