Solved

Inside an Activity Class, We Want to Create an AdView

Question 97

Essay

Inside an Activity class, we want to create an AdView, set its size using the SMART_BANNER constant of the AdSize class, and set its ad unit id to ca-app-pub-xyz. Write the code for it.
The AdView constructor, setAdSize, and setAdUnitId methods of the AdView class have the following APIs:
public AdView( Context context )
public void setAdSize( AdSize adSize )
public void setAdUnitId( String adUnitId )

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents