Excel VBA Course
Excel VBA Course - From Beginner to Expert

200+ Video Lessons
50+ Hours of Video
200+ Excel Guides

Become a master of VBA and Macros in Excel and learn how to automate all of your tasks in Excel with this online course. (No VBA experience required.)

View Course

DATEDIF FUNCTIONS (Aging)

0

I want to be able to capture / record aging... but also, stop the counter once I record a completion date in a given field...

This is what I have, so far:

=DATEDIF(D3,TODAY(),"D")

This is giving me what I need, as I am able to keep the counter going...

However, once I have a completion date in place... I want to stop the counter...

Any thoughts~

Answer
Discuss

Answers

1

You can do what is called copy/paste special to freeze it.

  1. Select the cell.
  2. Hit Ctrl + C
  3. Hit Alt + E + S + V
  4. Hit Enter

Or you could use a simple macro like this:

Freeze the date/value of the selected cell.

Sub freeze_value_1()

Selection.Value = Selection.Value

End Sub

Freeze the date/value of a specific cell.

Sub freeze_value_2()

Range("A1").Value = Range("A1").Value

End Sub

In the last macro, replaceĀ A1 with the cell that has the date that you want to stop or freeze.

Discuss


Answer the Question

You must create an account to use the forum. Create an Account or Login