读取界面信息以及文本分割按键精灵

该博客介绍了如何使用按键精灵读取手机界面信息,包括好友名称和坐标,并进行文本操作。通过解析XML文件,找到特定好友并模拟点击交互,同时展示了如何进行文本分割以提取话术内容。
摘要由CSDN通过智能技术生成

// 查找到好友发信息
Import “shanhai.lua”
Dim Path,Ret_Txt,ii
ii = 0
path = “/sdcard/MobileAnjian/anjian.txt”

Dim 话术="/sdcard/MobileAnjian/ceshi.txt"//话术页面
TracePrint File.Read(话术)
Dim fx_hh1=“2-”
Dim fx_hh2=“3-”
Do
Call File.Write(path, shanhai.GetUIXml())
If Dir.Exist(path) = 1 Then
Ret_Txt = File.Read(path)'读取文本文件内容返回到Ret_Txt变量中了
TracePrint “已读取”
TracePrint File.Read(path) '严密一些
End If
For i = 1 To 8’分析的是一页中的好友
Dim Fx_str1=“com.ss.android.tuchong:id/follow_name”
Dim Fx_srr2=“text”
Dim Fx_srr3=“bounds”
Dim Ret_Int1
TracePrint Ret_Int1
Dim Str_len=len(Fx_str1)'获取字符串长度
Dim Ret_Ret=Ret_Int1+Str_len
Dim HaoYou1=Wbfx(Ret_Ret,Fx_str1, Fx_srr2)
TracePrint “好友:”& HaoYou1
//Fx_str1=“android:id/text1”
Fx_srr2 = “bounds”
Dim ZhuoBiao

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值