Excel - how to record a function's result despite future changes?

  • Thread starter Thread starter starflight33
  • Start date Start date
S

starflight33

How can I automatically record a single moment's result for a function to
preserve it, when future changes in variables accessed by the function will
change it in the future?
 
To clarify: I'm looking for my formula to update its calculation everytime
the variables it depends on are updated, ~and to record each calculation
separately~. At this point I'm manually typing the result in a cell, but am
hoping to be able to have Excel do this, without my typing or preferably
without even having to use a macro.

Is there a solution?
 
If desired, send your workbook to my address below along with a snippet of
this message copied to an inserted worksheet and clear examples of what you
want. I will take a look tomorrow before the Texas game.
 
Copy down
=IF(LEN(TRIM(C2))<1,"",SUM($D$2:D2)/SUM($C$2:C2))
or
Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("c2:c4")) Is Nothing Then Exit Sub
If Len(Application.Trim(Target)) < 1 Then
Target.Offset(, 2) = ""
Else
Target.Offset(, 2) = Range("d7") / Range("c5")
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top