Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/selenium/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android 在某些活动中显示背景但在其他活动中不显示背景的Web视图?_Android_View_Web - Fatal编程技术网

Android 在某些活动中显示背景但在其他活动中不显示背景的Web视图?

Android 在某些活动中显示背景但在其他活动中不显示背景的Web视图?,android,view,web,Android,View,Web,我有两个活动都是一样的,而且布局几乎一样。在这些web视图中使用。透明背景设置为web视图。但它出现在一项活动中,而不出现在其他活动中,原因可能是什么?显示资产文件夹中使用Html的数据的Web视图。原因可能是什么。我已经尝试了所有可能的解决方案。任何帮助都将不胜感激 Webview.setBackgroundColor(0); Webview.setBackgroundResource(R.drawable.botom_bg);//set your background here 请尝试使用

我有两个活动都是一样的,而且布局几乎一样。在这些web视图中使用。透明背景设置为web视图。但它出现在一项活动中,而不出现在其他活动中,原因可能是什么?显示资产文件夹中使用Html的数据的Web视图。原因可能是什么。我已经尝试了所有可能的解决方案。任何帮助都将不胜感激

Webview.setBackgroundColor(0);
Webview.setBackgroundResource(R.drawable.botom_bg);//set your background here

请尝试使用这两行。

请添加您的代码,以便我们可以跟踪您的问题……请为您的Web视图在xml中设置透明颜色