1樓:度理所為
- - 有個笨辦法
先啟動一個 timer
然後用 messagebox(它不會暫停 timer 工作)
然後在 timer 裡操縱滑鼠點選 - - (不如干脆按y了 - -)
private declare function messagebox lib "user32" alias "messageboxa" (byval hwnd as long, byval lptext as string, byval lpcaption as string, byval wtype as long) as long
private withevents timer1 as timer
private sub form_load()
set timer1 = me.controls.add("vb.timer", "timer1")
timer1.interval = 1000 '問話框出現1000毫秒後自動確定
messagebox me.hwnd, "程式出錯,是否要退出?", "系統提示", 4
end sub
private sub timer1_timer()
sendkeys "y"
end sub
private declare function messagebox lib "user32" alias "messageboxa" (byval hwnd as long, byval lptext as string, byval lpcaption as string, byval wtype as long) as long
private withevents timer1 as timer
private sub form_load()
set timer1 = me.controls.add("vb.timer", "timer1")
timer1.interval = 1000 '問話框出現1000毫秒後自動確定
messagebox me.hwnd, "程式出錯,是否要退出?", "系統提示", 68
end sub
private sub timer1_timer()
sendkeys "y"
end sub
2樓:匿名使用者
用api,調視窗與按鈕控制代碼咯。
js如何實現滑鼠模擬點選,javascript如何模擬滑鼠點選a便籤
自定義點選一次 j ascript如何模擬滑鼠點選a便籤 獲取a標籤元素,然後後面.click 即可.給個例子把 這裡是a標籤的名稱 點選開啟a標籤 直接用jquery就好了 vbtn click document.getelementbyid vbtn click js如何自動點選onclick ...
VB 用函式實現1 2! 3!
private sub form click dim i,j as integer dim temp,answer as doublefor i 1 to 10 temp 1 for j i to 1 step 1temp temp j next j answer answer tempnext i...
怎樣用vb實現簡單的翻譯,用vb製作翻譯器
public function convertstring byval strtext as string dim stra as variant stra a b c d e f g h i j k l m n o p q r s t u v w x y z a b c d e f g h i j...