Web query failing due to too many temporary internet files?

G

Guest

I have a spreadsheet that pulls stock information off of Yahoo Finance. I
have vba code that goes through a list of stock symbols and pulls up a web
query for each then taking the data and copying elsewhere in the workbook.

I've been using this query for years with no problem. Suddenly, about a week
ago the query would start failing after running a certain number of symbols
(typically about 50 or 60). When I would manually try to refresh the query in
the spreadsheet it would give me an error that said that the query is
incorrectly formatted.

I did all kinds of messing with my web settings to see if anything fixes it.
I finally deleted all of my temporary internet files and it started working
again. But, one catch, I can only run 50 or 60 symbols before the problem
starts happening again! If I delete temporary internet files I can run
through the next 50 or 60 symbols. Big pain! If I go to the temporary
internet files directory I see a bunch of "q?s=XXX" files where "XXX" is the
symbol. I know they are the culprit because if I delete just those files it
starts working.

So, questions would be:
- Has anyone run into something similar?
- I tried to use VBA code (Kill command) to delete temporary internet files,
but I think it can't find them because they are hidden/system. Anyone know of
code that can do this?
- Is there a way to force excel to not cache?
- Any other ideas?
 
D

Don Guillett

You may be building up too many names due to your query.
You may send me your workbook to the address below and I will take a look.
I have a free file at the yahoo xltraders group that you may like
 

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