sharcky627
01-02-2014, 02:15 PM
I have read several posts on how to fill IE fields in using vba and have successfully written scripts to fill in information for several common websites (yahoo, gmail etc.) However, I am currently having an issue filling in fields to log in to Hyperion Workspace. The script below worked for yahoo mail, but when modified with the Hyperion Workspace URL and HTML fields, IE launches and navigates successfully but the fields are not filled in or submitted:
Here is the VBA and HTML exerts that i am currently using.
HTML
11026
Sub login()
Dim objie As InternetExplorer
Dim uid As String
Dim pwd As String
Dim rng As Range
Set objie = New InternetExplorerMedium
objie.Visible = True
uid = "johndoe"
pwd = "XXX"
'first tested this with yahoo to make sure the syntax was correct
'objie.navigate "URL here"
'Then put the actual website in
objie.navigate "URL here"
Do Until objie.readyState = 4
DoEvents
Loop
'Hyperion workspace HTML fields
objie.document.getElementById("bpm.Logon.1.txtUser").Value = uid
objie.document.getElementById("bpm.Logon.1.txtPassword").Value = pwd
'yahoo html fields
'objie.document.getElementById("username").Value = uid
'objie.document.getElementById("passwd").Value = pwd
For Each objieform In objie.document.forms
objieform.submit
Exit For
Next
End Sub
Here is the VBA and HTML exerts that i am currently using.
HTML
11026
Sub login()
Dim objie As InternetExplorer
Dim uid As String
Dim pwd As String
Dim rng As Range
Set objie = New InternetExplorerMedium
objie.Visible = True
uid = "johndoe"
pwd = "XXX"
'first tested this with yahoo to make sure the syntax was correct
'objie.navigate "URL here"
'Then put the actual website in
objie.navigate "URL here"
Do Until objie.readyState = 4
DoEvents
Loop
'Hyperion workspace HTML fields
objie.document.getElementById("bpm.Logon.1.txtUser").Value = uid
objie.document.getElementById("bpm.Logon.1.txtPassword").Value = pwd
'yahoo html fields
'objie.document.getElementById("username").Value = uid
'objie.document.getElementById("passwd").Value = pwd
For Each objieform In objie.document.forms
objieform.submit
Exit For
Next
End Sub