Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- DoEvents
- WebAddress = "CONFIDENTIAL URL HERE" & WebID & "&t="
- Dim IE As Object
- Application.ScreenUpdating = False
- Application.Calculation = xlCalculationManual
- Set IE = CreateObject("InternetExplorer.Application")
- IE.Navigate WebAddress
- IE.Visible = True
- While IE.busy
- DoEvents 'wait until IE is done loading page.
- Wend
- Application.Wait (Now + TimeSerial(0, 0, 4))
- IE.Document.All("Response_123").Value = ThisWorkbook.Sheets("Sheet1").Range("B5")
- Dim IE As Object
- Sub demo()
- Application.ScreenUpdating = False
- Set IE = CreateObject("InternetExplorer.Application")
- IE.Visible = True
- IE.Navigate "C:UsersAdministratorDesktopsample.html"
- While IE.Busy
- DoEvents
- Wend
- wait 1
- IE.Document.getElementById("firstname").Value = ThisWorkbook.Sheets("Sheet1").Range("A1")
- wait 1
- IE.Document.getElementById("lastname").Value = ThisWorkbook.Sheets("Sheet1").Range("A2")
- wait 1
- IE.Document.getElementById("submit_btn").Click
- IE.Quit
- Set IE = Nothing
- Application.ScreenUpdating = True
- End Sub
- Private Sub wait(seconds As Long)
- Dim endTime As Date
- endTime = DateAdd("s", seconds, Now())
- Do While Now() < endTime
- DoEvents
- Loop
- End Sub
Add Comment
Please, Sign In to add comment