Capture the URL through Admob code

Asked

Viewed 158 times

0

I want to record the url of the component BannerAd after Load, I realize that the component becomes url to the device’s default browser. The code is as follows:

    unit Unit1;

    interface

    uses
    System.SysUtils, System.Types, System.UITypes, System.Classes,System.Variants,
    FMX.Types, FMX.Controls, 
    FMX.Forms, FMX.Graphics, FMX.Dialogs, FMX.StdCtrls,
    FMX.Controls.Presentation, FMX.Edit, FMX.Advertising;

    type
    TForm1 = class(TForm)
    BannerAd1: TBannerAd;
    procedure FormCreate(Sender: TObject);
    private
    { Private declarations }


     public
    { Public declarations }
     end;

     var
     Form1: TForm1;

     implementation

     {$R *.fmx}

     procedure TForm1.FormCreate(Sender: TObject);
     begin
       BannerAd1.AdUnitID := 'Código fornecido pelo Admob';
       BannerAd1.LoadAd;
     end;

     end.

Does anyone have any idea how I can do it?

  • You must post the code to facilitate understanding and response.

  • OK, I’ve edited the post

1 answer

-1

BannerAd1.AdUnitID := 'Aqui vem o id que é dado, com esse id carrega a propaganda';
BannerAd1.LoadAd;
BannerAd1.visible:= true;

Browser other questions tagged

You are not signed in. Login or sign up in order to post.