View Single Post
  #2   Report Post  
Nick Hodge
 
Posts: n/a
Default

Bill

It really depends on your code. If it runs for that length of time you
should make sure it releases all variables on each iteration and clear
clipboard, etc

--
HTH
Nick Hodge
Microsoft MVP - Excel
Southampton, England
HIS


"Bill Martin -- (Remove NOSPAM from address)"
wrote in message ...
I have a Monte Carlo analysis that runs on my Excel 97 and as desired will
run for as many hours as I allow it. It's a bunch of spreadsheet code
that's tied together by a fairly simple VBA macro to plug semi-random
numbers into the spreadsheet and monitor the results.

If Excel is the only program active, then all is well and it will run to
conclusion in 10 hours or so. However when something else is running such
as a browser, e-mail, screen saver, etc., it will regularly lock up Excel
and XP reports it as "program not responding". Closing Excel is the only
answer.

My question is whether I've overlooked something in VBA that one needs to
do to periodically relinquish control of the system or something? I
wouldn't think such a thing would be necessary, but I can't imagine what
else is going on.

Thanks...

Bill