
如圖,我想通過vb腳本來檢測 “始終信任....”這個復選框是否選中,從而點擊安裝或不安裝的按鈕。
我有個簡單的例子,就是sendkey的方式,但是無法檢測復選框是否選中。
set WshShell = WScript.CreateObject("WScript.Shell")
For i = 1 To 20
ret = WshShell.AppActivate("Windows 安全")
If ret Then
WshShell.SendKeys "%a"
WScript.Sleep 500
WshShell.SendKeys "%i"
Exit For
Else
WScript.Sleep 1000
End If
Next
轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/72156.html
標籤:VB基礎類
