请教调用WEB页后操作标签的问题
请教调用WEB页后操作标签的问题
Private Sub Command1_Click()
Dim vDoc, vTag
Dim i As Integer
Set vDoc = WebBrowser1.Document
For i = 0 To vDoc.All.length - 1
If UCase(vDoc.All(i).tagName) = "INPUT" Then
Set vTag = vDoc.All(i)
'If vTag.Type = "text" Or vTag.Type = "password" Then
'List1.AddItem vTag.Name
'Select Case vTag.Name
'Case "Name"
'vTag.Value = "IMGod"
'Case "NickName"
'vTag.Value = "IMGod"
'Case "Password"
'vTag.Value = "IMGodpass"
'Case "EMail"
'vTag.Value = "IMGod@paradise.com"
'End Select
'Else
If vTag.Name = "ans1_30" And vTag.Value = "on" Then
'vTag.Click '此方法如果下次点就变成取消了。
'如何才能使此checkbox变成选中
End If
End If
Next i
End Sub
Private Sub Form_Load()
WebBrowser1.Navigate "http://www.cnvote.cn/temp/test.html"
End Sub
如何才能使checkbox变成选中