- Nov 16, 2004
Sub ToggleCalc() If Application.Calculation = xlCalculationManual Then Application.Calculation = xlCalculationAutomatic MsgBox ("Calculation is now set to: AUTOMATIC") Else: Application.Calculation = xlCalculationManual MsgBox ("Calculation is now set to: MANUAL") End If End Sub
I got sick of going into Tools/Options to change the calculation from Manual to Automatic so I made this quick code to toggle it back and forth. What my question now is: Is there a way I could enhance this to change the words in the menu bar to always show the current state? Instead of using MsgBox, is there a way to alter menu titles to show "Calc: Automatic" or "Calc: Manual"?