Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculation = xlCalculationAutomatic
Hi,
How do I check the status of xlCalculation (Manual or Automatic) in a debug statement? I tried Debug.Print "Starting NuTenant " & Application.Calculation I'm getting results like -4105 and -4135 -- Thanks for your help. Karen53 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculation = xlCalculationAutomatic
Karen,
Those are the values of the different Calculation modes. In the VBE, hit [F2], enter "xlCalculation" in the search box. In the Search Results box, select any of the items that have "XlCalculation" in the Class column. Then in the "Members of 'XlCalculation'" pane below, select each constant of the XlCalculation class, then look in the gray/tan box at the bottom to see the values for each constant. As far as returning the names......sorry, can't help you there. HTH, Conan "Karen53" wrote in message ... Hi, How do I check the status of xlCalculation (Manual or Automatic) in a debug statement? I tried Debug.Print "Starting NuTenant " & Application.Calculation I'm getting results like -4105 and -4135 -- Thanks for your help. Karen53 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculation = xlCalculationAutomatic
As Conan mentioned, xlCalculationAutomatic and xlCalculationManual are
predefined constants for the numbers -4105 and -4135. By the way, there is a 3rd possible mode... 2 whose predefined constant is xlCalculationSemiAutomatic. While somewhat ugly, you can use this statement to print out what I think you want... Debug.Print "Starting NuTenant: " & _ Choose(((Application.Calculation + 4165) Mod 4077) / 30, _ "xlCalculationManual", "xlCalculationAutomatic", _ "xlCalculationSemiAutomatic") It handles all three modes; however, if you never use xlCalculationSemiAutomatic, then you can use this somewhat shorter statement instead... Debug.Print "Starting NuTenant: " & _ Choose((Application.Calculation + 4165) / 30, _ "xlCalculationManual", "xlCalculationAutomatic") Rick "Karen53" wrote in message ... Hi, How do I check the status of xlCalculation (Manual or Automatic) in a debug statement? I tried Debug.Print "Starting NuTenant " & Application.Calculation I'm getting results like -4105 and -4135 -- Thanks for your help. Karen53 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Application.Calculation Problems | Excel Worksheet Functions | |||
Application.Calculation = xlCalculationManual mystery | Excel Programming | |||
Application.Calculation | Excel Programming | |||
Application Calculation Error | Excel Programming | |||
Application.Calculation exception | Excel Programming |