Hi every one
Would any body know how to click on the table "Cash Flow"
If I use a link, the link is ""
It looks hidden
Sub GetData()
Sheets("Sheet1").Select
Set IeApp = CreateObject("InternetExplorer.Application")
sURL = "http://www.google.com/finance?q=NYSE:IBM&fstype=ii&ei=1RcEUejuMea50QGHcg"
With IeApp
.Navigate sURL
.Visible = True
Do While IeApp.ReadyState <> 4 Or IeApp.Busy: DoEvents: Loop
End With
Set IeDoc = IeApp.document
Set IeECol = IeDoc.getElementsByTagName("A")
For Each IeLink In IeECol
If IeLink.innerText = "Cash Flow" Then
Text = IeApp.document.Body.innerHTML
Set tags = IeApp.document.getElementsByTagName("Input")
IeLink.Click
'Text.alt.Click
'tags.alt.Click
End If
Next IeLink
IeApp.Quit
Set IeApp = Nothing
Set IeDoc = Nothing
Set IeECol = Nothing
Set IeLink = Nothing
End Sub
I can find the "Cash Flow"
I think this would give me something, but I can't get it to work any more.
For I = 0 To 25
If IeDoc.getElementById("currentTab").Item(I).getAttribute("type") = "hidden" Then
If IeDoc.getElementsByTagName("input").Item(I).getAttribute("value") = "ei" Then
IeDoc.getElementsByTagName("input").Item(I).Click
Exit For
End If
End If
Next
Thank you in advance
Would any body know how to click on the table "Cash Flow"
If I use a link, the link is ""
It looks hidden
Sub GetData()
Sheets("Sheet1").Select
Set IeApp = CreateObject("InternetExplorer.Application")
sURL = "http://www.google.com/finance?q=NYSE:IBM&fstype=ii&ei=1RcEUejuMea50QGHcg"
With IeApp
.Navigate sURL
.Visible = True
Do While IeApp.ReadyState <> 4 Or IeApp.Busy: DoEvents: Loop
End With
Set IeDoc = IeApp.document
Set IeECol = IeDoc.getElementsByTagName("A")
For Each IeLink In IeECol
If IeLink.innerText = "Cash Flow" Then
Text = IeApp.document.Body.innerHTML
Set tags = IeApp.document.getElementsByTagName("Input")
IeLink.Click
'Text.alt.Click
'tags.alt.Click
End If
Next IeLink
IeApp.Quit
Set IeApp = Nothing
Set IeDoc = Nothing
Set IeECol = Nothing
Set IeLink = Nothing
End Sub
I can find the "Cash Flow"
I think this would give me something, but I can't get it to work any more.
For I = 0 To 25
If IeDoc.getElementById("currentTab").Item(I).getAttribute("type") = "hidden" Then
If IeDoc.getElementsByTagName("input").Item(I).getAttribute("value") = "ei" Then
IeDoc.getElementsByTagName("input").Item(I).Click
Exit For
End If
End If
Next
Thank you in advance