如何用vb实现网页表单的自动填充并提交

我请分析下,如何用vb实现网页表单的自动填充并提交
最新回答
冷巷。

2024-11-07 11:26:58

如果你电脑的的默认输入语言如果是五笔的话,下面的代码能实现运行后,打开hao123.com网页,并在百度一下的输入栏中写上“幸福一生”四个字。供你参考吧! Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long) Private Sub Form_Load() Dim ie Set ie = CreateObject("internetexplorer.application") ie.Visible = True ie.navigate "
http://www.hao123.com/
" Set WshShell = CreateObject("wscript.shell") Sleep 500 WshShell.SendKeys "fupy" Sleep 500 WshShell.SendKeys "ggtg" Sleep 500 WshShell.SendKeys " " End Sub vb实现网页表单的自动填充并提交这个真的好难,本人水平有限只能做到这点 了,如有不足请指出,也希望我们大家共同来探讨!
︷决戰紫禁之巓︷

2024-11-07 04:22:45

搜 网页表单批量自动填写助手。

试试这款即可。

不交电费瞎发啥光

2024-11-07 20:56:00

这个因网页HTML代码而定 如登陆126邮箱 Private Sub Form_Load() WebBrowser1.Navigate "
www.126.com
" End Sub Private Sub Command1_Click() Dim vDoc, vTag Dim i As Integer Set vDoc = WebBrowser1.Document For i = 0 To vDoc.All.length - 1 aa = UCase(vDoc.All(i).tagName) If UCase(vDoc.All(i).tagName) = "INPUT" Then Set vTag = vDoc.All(i) If vTag.Type = "text" Or vTag.Type = "password" Then Select Case vTag.Name Case "user" vTag.Value = "帐号" Case "password" vTag.Value = "密码" End Select ElseIf vTag.Type = "submit" Then vTag.Click End If End If Next i End Sub