疯了,用句柄得到弹出提示窗口并点击,IE弹出的窗口能点击,但WebBrowser弹出的窗口却不点击
如题,在论坛上问了下,能用
Option ExplicitConst MK_LBUTTON = 1'http://topic.csdn.net/u/20100312/09/bd98168f-038a-45a5-97c7-00b9b08f94de.html?seed=452989452&r=63867885#r_63867885'发鼠标消息还是用PostMessage吧Private Sub Command1_Click()Dim hpwnd As Long, hcwnd As Long, iresult As Longhpwnd = FindWindow(vbNullString, "Microsoft Intenet Expolor") 'IE的名字,可能在这儿会写错hcwnd = FindWindowEx(hpwnd, 0, "Button", "确定")SetForegroundWindow hcwndiresult = PostMessage(hcwnd, WM_LBUTTONDOWN, ByVal MK_LBUTTON, ByVal 0&)iresult = PostMessage(hcwnd, WM_LBUTTONUP, ByVal 0&, ByVal 0&)End Sub