JokelesComedian
Board Regular
- Joined
- Mar 26, 2012
- Messages
- 85
This is the code that google found for me. The web site I want to get data from has frames. You have to click certin buttons on the site to get to that page. Is there a way to do this? Here is the VBA I am working with.
Sub Test()
Dim IE As Object
Set IE = CreateObject("InternetExplorer.Application")
With IE
.Visible = True
.Navigate "http://www.aarp.org/" ' should work for any URL
Do Until .ReadyState = 4: DoEvents: Loop
x = .document.body.innertext
x = Replace(x, Chr(10), Chr(13))
x = Split(x, Chr(13))
Range("A1").Resize(UBound(x)) = Application.Transpose(x)
.Quit
End With
End Sub
This pulls info from the AARP site but the site I need to pull from at work has frames.
JokelesComedian
Excel 2010
IE 7
Sub Test()
Dim IE As Object
Set IE = CreateObject("InternetExplorer.Application")
With IE
.Visible = True
.Navigate "http://www.aarp.org/" ' should work for any URL
Do Until .ReadyState = 4: DoEvents: Loop
x = .document.body.innertext
x = Replace(x, Chr(10), Chr(13))
x = Split(x, Chr(13))
Range("A1").Resize(UBound(x)) = Application.Transpose(x)
.Quit
End With
End Sub
This pulls info from the AARP site but the site I need to pull from at work has frames.
JokelesComedian
Excel 2010
IE 7