
Untitled
By: a guest on
Jun 17th, 2012 | syntax:
None | size: 0.69 KB | hits: 23 | expires: Never
Behaviour of Worksheet_Calculate event in Excel – stored events?
Private Sub Worksheet_Calculate()
i = MsgBox("Value " & Me.Range("A1").Value, vbOKOnly)
End Sub
Public Sub mySub()
Application.EnableEvents = False
ThisWorkbook.Worksheets(2).EnableCalculation = True
ThisWorkbook.Worksheets(2).EnableCalculation = False
Application.EnableEvents = True
End Sub
Public Sub mySub()
Application.EnableEvents = False
Application.Calculation = xlCalculationManual
ThisWorkbook.Worksheets(2).EnableCalculation = True
ThisWorkbook.Worksheets(2).EnableCalculation = False
Application.Calculation = xlCalculationAutomatic
Application.EnableEvents = True
End Sub