Dim web = e.form.controls("webbrowser1").basecontrol
web.ScriptErrorsSuppressed = True
web.Navigate("http://www.baidu.com")
Do Until web.ReadyState = 4
Application.DoEvents
Loop
Dim hec As System.Windows.Forms.HtmlElementCollection = web.Document.GetElementsByTagName("input")
For i As Integer = 0 To hec.Count - 1 '循环所有标签
If hec(i).Name = "r1c2" Then
hec(i).SetAttribute("Value", "纳税人识别号")
ElseIf hec(i).Name = "r2c2"
hec(i).SetAttribute("Value", "电话")
ElseIf hec(i).Name = "r1c1"
hec(i).SetAttribute("Value", "纳税人名称")
End If
Next
<table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="#000000">
<tr>
<td rowspan="4" align="left" bgcolor="#FFFFFF">购货方、接收劳务或服务方纳税人</td>
<td align="left" nowrap bgcolor="#FFFFFF">纳税人识别号 <br></td>
<td align="left" bgcolor="#FFFFFF"><input name="r1c2" type="text" size="40"></td>
<td align="left" bgcolor="#FFFFFF">电话</td>
<td align="left" bgcolor="#FFFFFF"><input name="r2c2" type="text" size="35"></td>
</tr>
<tr>
<td align="left" nowrap bgcolor="#FFFFFF">纳税人名称</td>
<td align="left" bgcolor="#FFFFFF" colspan="3"><input name="r1c1" type="text" size="86" ></td>
</tr>
<tr>
<td align="left" bgcolor="#FFFFFF"> 地址</td>
<td align="left" bgcolor="#FFFFFF" colspan="3"><input name="r2c1" type="text" size="86"></td>
</tr>
<tr>
<td align="left" nowrap bgcolor="#FFFFFF"> 银行名称</td>
<td align="left" bgcolor="#FFFFFF"><input name="r3c1" type="text" size="40"></td>
<td align="left" bgcolor="#FFFFFF" nowrap> 银行账户</td>
<td align="left" bgcolor="#FFFFFF"><input name="r3c2" type="text" size="35"></td>
</tr>
</table>