To begin, I know little about IE Elements and only slightly more about VBA code.
Here's what I have so far
The element I'm trying to get to in inside of a frameset "contents", inside of a form "form2", inside of a div "barChase" (versus "barChase_hidden"), inside of a table "barchase_Group_1_Group", and finally you get to my item "barChase_5_Item_1"
I get the error -2147417848 (80010108)
The Object invoked has disconnected from its clients.
I have 2 issues: (ok, probably a lot more than that, but here's some hints)
1. In between
and
the webpage actually opens a new window with a new URL and closes the old window. I don't know how to set my variable IE to the new URL value.
2. I'm certain there's some issue with locating barChase_5_Item_1 inside the mess of hierarchy. I can't post the actual webpage as it's work but if it would help to see the entire code, I can post it below. (it's long)
Any hints to interacting with frames like that?
Here's what I have so far
Rich (BB code):
Sub internetlogon()
Dim IE As Object
Dim IE2 As Object
Dim usr As Object
Dim pwd As Object
Dim Go As Object
Dim frm As Object
Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True
'Go to this Web Page!
IE.Navigate "https://www.chasesoftware.com/itok/login.aspx"
'Check for good connection to web page loop!
Do
If IE.ReadyState = 4 Then
IE.Visible = False
Exit Do
Else
DoEvents
End If
Loop
'Wait for window to open!
Application.Wait (Now + TimeValue("0:00:01"))
IE.Visible = True
'Send logon information
Application.Wait (Now + TimeValue("0:00:01"))
Set usr = IE.document.getElementById("usr")
usr.Value = "MY LOGIN NAME"
Set pwd = IE.document.getElementById("pwd")
pwd.Value = "MY PASSWORD"
Set frm = IE.document.forms("form1")
Set Go = IE.document.getElementById("btnLogin")
Go.Click
'Navigate to a link in a framed table "Work Orders"
Application.Wait (Now + TimeValue("0:00:05"))
IE.document.getElementById("barChase_5_Item_1").Click
End Sub
The element I'm trying to get to in inside of a frameset "contents", inside of a form "form2", inside of a div "barChase" (versus "barChase_hidden"), inside of a table "barchase_Group_1_Group", and finally you get to my item "barChase_5_Item_1"
I get the error -2147417848 (80010108)
The Object invoked has disconnected from its clients.
I have 2 issues: (ok, probably a lot more than that, but here's some hints)
1. In between
Code:
Set Go = IE.document.getElementById("btnLogin")
Go.Click
Rich (BB code):
IE.document.getElementById("barChase_5_Item_1").Click
2. I'm certain there's some issue with locating barChase_5_Item_1 inside the mess of hierarchy. I can't post the actual webpage as it's work but if it would help to see the entire code, I can post it below. (it's long)
Any hints to interacting with frames like that?