Using Web Queries -- unusual problem

M

metcab

I am fairly new to VBA and I am learning through trial and error. I
have started experimenting with web queries. I want to import several
tables from the yahoo finance web page. Everything works great, but
when I loop down a list of stocks, there is a problem...

Apparently, a banner ad is sometimes at the top and sometimes it is
not. So depending on if the banner is there or not, my tables are
imported incorrectly because of the webtable line.

Any thoughts to how I can get around this problem?
 
T

Tim Williams

You couild import the whole page and then search the result for some
fixed piece of text associated with the table you want: use that to
locate the data

Tim.
 
D

DM Unseen

metcab,

depending on your XL version you can specify which part of the page to
load (e.g. tables only)

Dm Unseen
 

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