followHyperlink - help please

B

bj99hulce99

Hello all,

From Excel I'm trying to send a URL to a web page, which returns an
embedded Excel document, copy the data out and paste it into my current
Excel workbook. The problem is that after the followHyperlink, a
Columns("A:G").Select grabs the data on my Excel worksheet, not on the
IE worksheet. I can't figure out how to activate the IE Excel WS so I
can do the select data and copy. How do I toggle between the IE and
Excel application or window.



Here is an example:



Sub openWebGetData()





ActiveWorkbook.FollowHyperlink _

Address:="http://table.finance.yahoo.com/table.csv?s=INTC&a=07&-
b=9&c=2003&d=09&e=12&f=2003&g=d&ignore=.csv", _

NewWindow:=True





Application.Windows(1).ActiveWindow 'I know this is wrong





Columns("A:G").Select

Selection.Copy

Windows("MyFlie.xls").Activate



Sheets.Add

ActiveSheet.Paste



ActiveWorkbook.Close





End Sub



Thanks in advance for the help, (e-mail address removed)
 
E

Emilia Maxim

bj99hulce99 said:
Hello all,

From Excel I'm trying to send a URL to a web page, which returns an
embedded Excel document, copy the data out and paste it into my current
Excel workbook. The problem is that after the followHyperlink, a
Columns("A:G").Select grabs the data on my Excel worksheet, not on the
IE worksheet. I can't figure out how to activate the IE Excel WS so I
can do the select data and copy. How do I toggle between the IE and
Excel application or window.
I guess you would have much better chances to receive some good
advices if you post this in an Excel news group.

Best regards
Emilia

Emilia Maxim
PC-SoftwareService, Stuttgart
http://www.maxim-software-service.de
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top