View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
David David is offline
external usenet poster
 
Posts: 1,560
Default VBA slows with time

Hi Again Group,

After the macro completed, CPU usage for excel remained at 95%+ for over 20
minutes. I do beleive it would have stayed that way for a very long time.

After shutting down and reopening Excel, task manager showed Excel.exe CPU
usage back to normal, even in the same file.

Still very much at a loss for explaining this, especially after the macros
had completed. Any insight would be greatly appreciated.

Thanks,
David

"Alan Hutchins" wrote:

david,

It looks as though the process is not releasing memory as it goes through
the 4 legs as you describe.

I would suggest that you go back to the original author and discuss with
them, as they may suggest that you reset any variables to nothing and so on
to see if that makes a difference.

--
Alan Hutchins


"David" wrote:

Hi r,

Someone helped me me with the code and asked me not to share it. Sorry.
There is really not anything that complicated. It it bring in a csv table
from Yahoo and like I said the names are deleted.

The person that helped me I trust. I did look through the various class
modules to see if something might not be in them and found nothing.

I might copy the code out and put it in a new file to test it and see if
that makes a difference, but I expect not. Looking for others that might have
had similar problems and found some sort of solution.

What was most suprising was the continued Excel.exe memory usage, after the
macro has finished.

Still looking for insight.

Thanks,
David

"r" wrote:

you can show the code?
regards
r

Il mio ultimo lavoro ...
http://excelvba.altervista.org/blog/...ternative.html


"David" wrote:

Hi Group,

Hope all are having a good day. I have some code that does web queries. It
is sort of in 4 legs. It does a lookup of Fund ticker symbols and bring back
closes for a specific symbol and a specific single day. The list of symbols
is a little over 800.

It does this 4 times for 4 different dates, what I am calling legs. So 4
legs. Each leg about doubles the time of the previous leg. 2 minutes, 4
minutes, 5 minutes and 10 minutes. The query is deleted after each look up
and all names are also deleted.

When the macro is finished. Task manger indicated that Excel.exe is still
using 90% of memory. I am very perplexed at this situation.

Does anyone have any insights on this situation?
One of the other problems I am having is that when I leave this message and
check the box below "Notify me of replies", I do not recieve e-mail
notifications.

Thanks for your help,
David