简体   繁体   English

用户离线时,adduplex广告为黑色矩形

[英]adduplex ad is black rectangle when user offline

I have ads in my app. 我的应用程式中有广告。 If user is offline place where is an ad is a black rectangle. 如果用户处于离线状态,则广告是黑色矩形。 Can I change it to transparent or put something else like text or image ? 我可以将其更改为透明的,还是可以放置其他文字或图像? Because this black place is very ugly. 因为这个黑色的地方很丑陋。

You can hide the AdControl on Errors. 您可以在错误时隐藏AdControl Remember to show the AdControl again when the new ad has been loaded: 请记住,在加载新广告后再次显示AdControl

<adduplex:AdControl
    AdLoaded="ShowAd"
    AdLoadingError="HideAd"
    ...

code behind: 后面的代码:

private void ShowAd(object sender, AdLoadedEventArgs e)
{
    AdDuplexAd.Visibility = Visibility.Visible;
}

private void HideAd(object sender, AdLoadingErrorEventArgs e)
{
    AdDuplexAd.Visibility = Visibility.Collapsed;
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM