Option ExplicitPrivate Sub Form_Load() WebBrowser1.Navigate2 "www.google.cn" End SubPrivate Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant) Dim oInput As Object Set oInput = pDisp.Document.getElementById("q")
If Not oInput Is Nothing Then oInput.Value = "go" End If End Sub
Option ExplicitPrivate Sub Form_Load()
WebBrowser1.Navigate2 "www.google.cn"
End SubPrivate Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, URL As Variant)
Dim oInput As Object
Set oInput = pDisp.Document.getElementById("q")
If Not oInput Is Nothing Then
oInput.Value = "go"
End If
End Sub