How to correctly disable ads.

35 views
Skip to first unread message

zvg

unread,
Jul 25, 2020, 7:29:39 PM7/25/20
to Google Mobile Ads SDK Developers
I want to give the user the option of having ads enabled or not. What would be the correct way of disabling an ad that is being shown?

Mobile Ads SDK Forum Advisor Prod

unread,
Jul 26, 2020, 10:36:25 PM7/26/20
to zvg...@gmail.com, google-adm...@googlegroups.com

Hi there,

 

Thank you for reaching out to us.

 

If you are referring to disabling banner ads that are currently being shown (given that it's normally only banner ads that are being constantly shown to a user), then you may call a banner ad's AdView.destroy function in order to properly disable it. With that said, I would also recommend not initializing the AdMob SDK in the first place if the user's choice (of not displaying ads) could be retrieved at the start of your app, in order to prevent unnecessary memory usage.

 

Regards,

Ziv Yves Sanchez

Mobile Ads SDK Team



ref:_00D1U1174p._5004Q22Z8l7:ref
Reply all
Reply to author
Forward
0 new messages