Notifications
Clear all
VBA & Macros
2
Posts
2
Users
0
Reactions
32
Views
Topic starter
Dim HTMLDoc As HTMLDocument Dim MyBrowser As InternetExplorer Sub Instamojo() Dim MyHTML_Element As IHTMLElement Dim MyURL As String On Error GoTo Err_Clear MyURL = " https://www.instamojo.com/accounts/login" Set MyBrowser = New InternetExplorer MyBrowser.Silent = True MyBrowser.navigate MyURL MyBrowser.Visible = True Do Loop Until MyBrowser.readyState = READYSTATE_COMPLETE Set HTMLDoc = MyBrowser.document HTMLDoc.all.id_login_username.Value = "ABC" HTMLDoc.all.Password.Value = "abc@123" For Each MyHTML_Element In HTMLDoc.getElementsByTagName("input") If MyHTML_Element.Type = "submit" Then MyHTML_Element.Click: Exit For Next Err_Clear: If Err <> 0 Then Err.Clear Resume Next End If End Sub End If
Posted : 09/08/2019 6:14 am
Hi,
I find using SeleniumBasic much easier than using IE. This post walks you through setting it up and how to interact with the website form.
https://www.myonlinetraininghub.com/web-scraping-filling-forms
Regards
Phil
Posted : 09/08/2019 6:29 am