按照ID来模拟Dim web As System.Windows.Forms.WebBrowser = e.Form.Controls("WebBrowser1").Basecontrol
web.ScriptErrorsSuppressed = True
Do Until web.ReadyState = 4
Application.DoEvents
Loop
Dim btn = web.Document.GetElementById("allOperatorLog")
btn.InvokeMember("click")
按照模块中某个元素来获取
Dim web As System.Windows.Forms.WebBrowser = e.Form.Controls("WebBrowser1").Basecontrol
web.ScriptErrorsSuppressed = True
Do Until web.ReadyState = 4
Application.DoEvents
Loop
Dim inputs = web.Document.GetElementsByTagName("div")
For Each Input As object In Inputs
If Input.GetAttribute("data-type") = "orderInfo"
Input.InvokeMember("click")
End If
Next
[此贴子已经被作者于2019/3/21 15:33:03编辑过]