按鍵精靈saystring無法使用的幾種解決方案


 1、當輸入密碼無法使用“SayString”、“Ctrl+V”時,改用“KeyPress”的方法

戲谷游戲的登錄畫面,“密碼輸入” 是會擋按鍵精靈的“SayString”這指令,還有“Ctrl+V”貼上的方式。

所以只能模擬手動按鍵“KeyPress”的方式。


提供按鍵精靈腳本6.71版,范例腳本參考:

Dim a
// 密碼
PSW="AbcdzZ12345"
// 計算密碼長度
PSW_Len=Len(PSW)
ReDim a(PSW_Len)
i=0
For PSW_Len
    a(i) = Mid(PSW,1+i,1)
    If Asc(a(i))>=97 and Asc(a(i))<=122
        // 英文大寫
        KeyPress Asc(a(i))-32,1
    ElseIf Asc(a(i))>=65 and Asc(a(i))<=90
        // 英文小寫
        KeyDown 16,1
        KeyPress Asc(a(i)),1
        KeyUp 16,1
    ElseIf Asc(a(i))>=48 and Asc(a(i))<=57
        // 數字
        KeyPress Asc(a(i)),1
    Else 
        MessageBox "密碼: " & PSW &" 含有符號,不適用此腳本"
        EndScript 
    EndIf 
i = i + 1
EndFor

2、
復制代碼

1 //下面這句是設置剪切板內容
2 Call Plugin.Sys.SetCLB("剪切板內容")
3 Msgbox "設置剪切板內容"

然后再用ctrl+v黏貼出來 

  KeyDown 17, 1

KeyPress 86, 1
KeyUp 17, 1


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM