This is a small issue with a large macro I am making reading through log files and preparing data by writing them into a number of worksheets. I don't want to see all of this writing going on, so I turn screen updating off, however I want to see some progress so every now and then I switch screen updating on I activate the top worksheet, write some progress data in some cells and switch screen updating off again. This worked pretty well in Excel 2010, but last week I upgraded to Excel 2013 and no more updating visible until the macro finishes. I added a 0.3 second pause, but now only the time gets updated and not the number of processed sites. Any ideas?
Application.ScreenUpdating = True 'To write the elapsed time and the number of found sites on the performance monitor sheet
PerfMon.Activate
PerfMon.Range("B4") = Now - StartPoint
PerfMon.Range("D4") = SiteCnt
Application.Wait (Now + (0.3 / 86400))
Application.ScreenUpdating = False
Thanks, Hans
StatusBar
to keep track of progress instead. See Chip Pearson's page, or this page for some ideas. (I'm not sure if theStatusBar
is affected byScreenUpdating
though, but I don't think it is). – BruceWayneDoEvents
yields execution so that the operating system can process other events. There is a caution in its description but it is the standard way of pausing the main process so background stuff can be actioned. – Tony Dallimore