Hi all,
I am trying to automate a number of forms we need to submit on a weekly basis with the same details. I have tried writing a VBA code for this however I get an error once i read the first elementbyid.
I can't link the URL as this is an internal website. When I inspect the boxes these are the element IDs that I can see.
Any ideas what the issue may be? Any help is appreciated!
Thanks,
Michaela
I am trying to automate a number of forms we need to submit on a weekly basis with the same details. I have tried writing a VBA code for this however I get an error once i read the first elementbyid.
Code:
Sub SubmitSpark()Dim IE As Object
Application.ScreenUpdating = False
Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True
IE.Navigate "Website URL"
Application.StatusBar = "Submitting"
' Wait while IE loading...
While IE.Busy
DoEvents
Wend
' **********************************************************************
IE.document.getElementById("IO:4ae65484353421009f058a23a21d4860").Value = "Test"
IE.document.getElementById("IO:ac475484353421009f058a23a21d48fb").Value = "test"
IE.document.getElementById("sys_display.IO:45679484353421009f058a23a21d4821").Value = "Test"
IE.document.getElementById("submit_button").Click
'**********************************************************************
Application.StatusBar = "Form Submitted"
IE.Quit
Set IE = Nothing
Application.ScreenUpdating = True
End Sub
I can't link the URL as this is an internal website. When I inspect the boxes these are the element IDs that I can see.
Any ideas what the issue may be? Any help is appreciated!
Thanks,
Michaela