Ui Automator Viewer 使用报错问题 提示’Error obtaining UI hierarchy‘

大神方案:

  在C:\sdk\android-sdk-windows\tools路径下的uiautomatorviewer.bat,右键编辑打开,在最末端输入:

call adb shell uiautomator dumpcall 
call adb pull /storage/sdcard/window_dump.xml .
call window_dump.xml


通用方案:
桌面新建 test.bat文件,添加五行代码,内容如下:
 # 此处输入任意自己本地路径
uiautomatorviewer 中导入。
聊胜于无,虽然麻烦,但能解决问题,毕竟页面就那几个
感谢大神分享~
来源:https://www.jianshu.com/p/200de8ded032


posted on 2020-08-03 14:58  进击的麻瓜  阅读(1318)  评论(0编辑  收藏  举报