作者:郭原雪2865 | 来源:互联网 | 2023-09-14 13:17
在做Android开发时,使用华为的p20和平板(均为Android9.0)测试时,发现不能使用WIFI网络,一番郁闷纠结查找后直接上方法:在res文件夹下创建xml文件夹,在xml里面创建
在做Android开发时,使用华为的p20和平板(均为Android 9.0)测试时,发现不能使用WIFI网络,一番郁闷纠结查找后
直接上方法:
在res文件夹下创建xml文件夹,在xml里面创建文件network_security_config.xml
![](https://img.php1.cn/3cd4a/1eebe/cd5/6c257b6ba227cc3e.webp)
![](https://img.php1.cn/3cd4a/1eebe/cd5/8170a21e8dddfd22.webp)
android:networkSecurityCOnfig="@xml/network_security_config"
完成
参考于: https://blog.csdn.net/Liu_ser/article/details/86640849