I have a Workbook_SheetChange that is slow to fire on a visible sheet under certain circumstances (all other events work normally). When it is slow, it takes a few seconds to fire rather than firing almost instantly.
The conditions have been isolated to the following:
1) After I first open a workbook where a) the workbook was saved with hidden/veryhidden sheets b) the OnOpen code applies horizontal borders are applied to cells c) the OnOpen code hides or unhides some rows in code
Or
2) Any time I run code that uses NumberFormat (text) in a loop through multiple sheets (whether sheets are hidden or not)
I always disable/enable events, calculation, screenupdating (etc...) in my code -- that is not the issue. I need to keep some sheets hidden when a workbook is saved or open.
Does anyone know why the Workbook_SheetChange code would be slow to fire?
Bookmarks