ubuntu linux通过adb命令行"复制粘贴"内容到android
16lz
2021-01-23
阅读更多 假如你像我一样在寻找android下通过命令复制粘贴的方法,来对地方了,不过android上是没有直接进行复制粘贴剪切板的命令,只有间接实现:在电脑上直接adb输入信息到android设备上
首先android设备上,要把光标焦点定位到需要输入的文本框,比如当你输入用户名密码的时候
电脑上adb连接好android设备
电脑上执行adb命令如下,比如你的用户名是hello,密码是world
扩展阅读,假如你的密码比较复杂有但引号之类,比如为 wor"ld
参考: http://blog.rungeek.com/post/42456936947/sending-keyboard-input-via-adb-to-your-android-device
首先android设备上,要把光标焦点定位到需要输入的文本框,比如当你输入用户名密码的时候
电脑上adb连接好android设备
电脑上执行adb命令如下,比如你的用户名是hello,密码是world
adb shell input text hello#输入tab键定位到下一输入框,tab键的key code是61 --> "KEYCODE_TAB" adb shell input keyevent 61#然后输入密码adb shell input text world#回车确认登录,回车键的key code是66adb shell input keyevent 66
扩展阅读,假如你的密码比较复杂有但引号之类,比如为 wor"ld
adb shell input text wor\\\"ld
参考: http://blog.rungeek.com/post/42456936947/sending-keyboard-input-via-adb-to-your-android-device
更多相关文章
- Android设备到底侵犯了微软的什么专利
- Android设备的唯一ID
- Android adb的常用命令
- Android之几个dos小命令
- Android命令行获取WiFi列表以及参数
- Android Java执行Shell命令
- Android设备获取wifi下的ipv6地址