Need Help With App Development

I have made a floating calculator I need to add ads in it but can't float ads

IMG_20211016_105204

You're using a wrong argument here, indicated by both of the error messages. Could you please show your relevent blocks?

I cant give you calculator aia so this is a test aia

Doesn't seem like it's a problem with the main .aia, so there's no need of it.

Seems like the problem is with the call FloatingView1.SetUpView block.
Looks like it doesn't allow the 1st argument, viewComponent, to be a UnityAdsUtil component; it has to be an AndroidViewComponent.

So is there any solution or can I show ad another way

I'm pretty sure an AndroidViewComponent is just a Horizontal/Vertical Arrangement, so you could try putting the UnityAdsUtil component inside one of them.

@abhinav_k.b the function to show banner in UnityAdsUtils can only work with visible components.

1 Like

AndroidViewComponent class can work with all visible components, therefore my friend and I have discussed not to use that class and instead we use HVArrangement class :wink:

1 Like

Ok, thank you for the clarification.

1 Like