Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Preventing only one cell from recalculating
Is there any way to prevent the worksheet from recalculating only if a
certain cell changes? I have code like below: Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = CELL_ENTER_DATE Then Application.Calculation = xlManual ... The problem is Worksheet_Change is called *after* all the formulas are recalculated on the worksheet. Now, I know I can go to Tools/Options and change the worksheet's calculation method to Manual, but I don't want it to be manual. I only want to stop the auto-calc if a certain cell changes. Does anyone know if that is possible? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Preventing only one cell from recalculating
I don't know - but I think (haven't tested it) you might be able to do this
in reverse; that is, turn calculation to manual and then use the Worksheet_Change event procedure to run the calculation unless the changed cell is the one you want. e.g.: Sub Worksheet_Change(ByVal Target as Range) If Not(Target.Address)="A1" Then ActiveSheet.Calculate End Sub Just suppose it might be slow if the sheet is too complex -- - K Dales "Mike K" wrote: Is there any way to prevent the worksheet from recalculating only if a certain cell changes? I have code like below: Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = CELL_ENTER_DATE Then Application.Calculation = xlManual ... The problem is Worksheet_Change is called *after* all the formulas are recalculated on the worksheet. Now, I know I can go to Tools/Options and change the worksheet's calculation method to Manual, but I don't want it to be manual. I only want to stop the auto-calc if a certain cell changes. Does anyone know if that is possible? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Stop specific cell from recalculating? | Excel Worksheet Functions | |||
please help! Linking a picture to a cell and recalculating automatically | Excel Discussion (Misc queries) | |||
cell/range with formula not recalculating | Excel Worksheet Functions | |||
Recalculating single cell | Excel Programming | |||
Recalculating cell | Excel Programming |