Sub CreatePublisherAd As View
Dim ctxt As JavaObject
ctxt.InitializeContext
Dim padview As JavaObject
padview.InitializeNewInstance("com.google.android.gms.ads.doubleclick.PublisherAdView", Array(ctxt))
Dim adv As AdView 'ignore
Dim sizes As JavaObject
sizes.InitializeArray("com.google.android.gms.ads.AdSize", Array(adv.SIZE_BANNER))
padview.RunMethod("setAdSizes", Array(sizes))
padview.RunMethod("setAdUnitId", Array("ad unit here"))
Dim builder As JavaObject
builder.InitializeNewInstance("com.google.android.gms.ads.doubleclick.PublisherAdRequest$Builder", Null)
builder.RunMethod("addTestDevice", Array("0C7E7C3E315C7706E63185ABF6BF8AAF")) 'change based on the unfiltered logs message
padview.RunMethod("loadAd", Array(builder.RunMethod("build", Null)))
Return padview
End Sub