Unexpected error while obtaining screenshot from device: EOF
环境Android Studio
问题:Unexpected error while obtaining screenshot from device: EOF
提示框:Unexpected error while obtaining screenshot from device: EOF
解决方案
排查一下是否APP限制截屏,搜索下面禁止截屏代码
getWindow().setFlags(WindowManager.LayoutParams.FLAG_SECURE, WindowManager.LayoutParams.FLAG_SECURE);
添加判断在debug模式取消此限制
if (!BuildConfig.DEBUG) {getWindow().setFlags(WindowManager.LayoutParams.FLAG_SECURE, WindowManager.LayoutParams.FLAG_SECURE);
}
Unexpected error while obtaining screenshot from device: EOF相关推荐
- Unexpected error while obtaining UI hierarchy:使用uiautomatorviewer定位元素报错
1.问题描述 在使用Uiautomatorviewer 进行元素定位时,点击 快照 按钮出现以下错误: 2.发生原因 Unexpected error while obtaining UI hiera ...
- Appium+Python连接真机、跳过登录页、Unexpected error while obtaining UI hierarchy问题
Appium连接真机 使用数据线连接电脑,然后选择文件传输方式 打开手机设置拉至底部,点击关于手机,连续点击7次版本号打开开发者模式 点击设置中的系统与更新,找到开发者选项----> 打开USB ...
- 【学习笔记】【MAC】uiautomatorviewer定位华为P30手机报错Unexpected error while obtaining UI hierarchy
报错信息 Unexpected error while obtaining UI hierarchy details: Unexpected error while obtaining UI hier ...
- uiautomatorviewer报错:Unexpected error while obtaining UI hierarchy java.lang.reflect.InvocationTarget
完美解决方案 官方完美解决方案 偏方解决方案 uiautomatorviewer报错 原因:uiautomatorviewer不支持Android8.0之后的版 解决办法:使用别人二次开发好的uiau ...
- UI Automator Viewer Error while obtaining UI hierarchy XML file
Error obtaining UI hierarchy Reason: Error while obtaining UI hierarchy XML file: com.android.ddmlib ...
- CDH5之Unexpected error.Unable to verify database connection
在部署好CDH5(HDFS+MapReduce+Zookeeper)后,某一天想要通过web界面来添加Hive或者Oozie服务. 添加Hive组件服务: 1.报错:Unexpected error ...
- [INS-08109] Unexpected error occurred while validating inputs at state 'getOCMDetails'.
在ORACLE11G R2 安装ORACLE时出现以下错误: [INS-08109] Unexpected error occurred while validating inputs at stat ...
- WSS 3.0中An unexpected error has occurred的一个解决方案
之前在CodePlex上讨论到我在WSS v3里遇到的一个Bug,CKS团队的TheKid向我引用了他的一个解决方案,大意如下 如果需要了解WSS 3.0中An unexpected error ha ...
- Android之Unexpected error while executing: am start -n “***.Activity“-a android.intent.action.MAIN
1 问题 编译项目的时候,as错误提示如下 $ adb shell am start -n "package/package.***Activity" -a android.int ...
- yarn安装依赖包报错 error An unexpected error occurred: “https://registry.npm.taobao.orgnpm/element-ui: get
yarn安装依赖包报错,error An unexpected error occurred: "https://registry.npm.taobao.orgnpm/element-ui: ...
最新文章
- Python之Pandas:pandas.DataFrame.to_csv函数的简介、具体案例、使用方法详细攻略
- php mysql建表_mysql建表测试
- 计划Java EE 7批处理作业
- Solaris11创建NFS服务
- python生成加密exe_python加密保护-加密exe文件
- Pandas汇总不同excel工作簿中的表格并合并同类数据
- Wingdings 2 符号编码对照表
- 5个物联网商业案例及其带给我们的启示
- 神经网络是什么,神经网络具体有什么用?
- 计算机无法屏保,电脑屏幕保护程序为什么不能修改 原因及解决方法【详细介绍】...
- mssql注入和mysql注入_MSSQL注入代码
- ubuntu下.chm文档查看工具
- Python中万年历的代码实现
- 时尚简约风格的ae字幕条模板
- 适配iOS 11和iPhone X——导航栏、UITableView
- open /run/flannel/subnet.env: no such file or directory
- 820计算机基础学校,[定稿]计算机基础教案33820V5.1(全文完整版)
- Matlab中的逻辑运算
- 闲逸联运平台为何迎来加盟热?
- 【LOJ6197】法克(最长反链)