![]() |
Event Procedure (re-activate automatic calulation if disabled)
I need an event procedure activate Application.Calculation = xlAutomatic
whenver the targeted sheets are selected. I have 10 worksheets in my workbook where the event procedure should only affect Sheet1 to Sheet6 Purpose: This is to ensure Application.Calculation = xlAutomatic is always activated even when my other procedures in Module1 exits pre-maturely as I disable calculation via Application.Calculation = xlManual at the beginning of each procedure within Module1 (for speed). So, if my codes in Module1 exits pre-maturely (due to poor debugging), atleast I have the event to reactivate Application.Calculation = xlAutomatic whenver the targeted sheets are selected. Also, pls tell me where should I place this event procedure. in Thisworkbook or where? Thanks in advance. -- Edmund (Using Excel 2000) |
Event Procedure (re-activate automatic calulation if disabled)
Edmund,
Each sheet has a _Activate & _Deactivate events you can respond to. Or ThisWorkbook has _SheetActivate if you want one central place for code. NickHK "Edmund" wrote in message ... I need an event procedure activate "Application.Calculation = xlAutomatic" whenver the targeted sheets are selected. I have 10 worksheets in my workbook where the event procedure should only affect Sheet1 to Sheet6 Purpose: This is to ensure "Application.Calculation = xlAutomatic" is always activated even when my other procedures in Module1 exits pre-maturely as I disable calculation via "Application.Calculation = xlManual" at the beginning of each procedure within Module1 (for speed). So, if my codes in Module1 exits pre-maturely (due to poor debugging), atleast I have the event to reactivate "Application.Calculation = xlAutomatic" whenver the targeted sheets are selected. Also, pls tell me where should I place this event procedure. in Thisworkbook or where? Thanks in advance. -- Edmund (Using Excel 2000) |
All times are GMT +1. The time now is 11:49 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com