Excel Date Control

I want automatically update a cell to add a number to a total number.

For example when June 1, 2015 arrives  I want cell A1 (100 ) to be added to cell A2 for a total.

Thx.

March 17th, 2015 2:53pm

Hi,

According to your description, we may use If formula to reach your goal. Please see the below image:

Another way:

On the other hand, we can also automatically update when opening file. See the sample code below:

Private Sub Workbook_Open()
If DateDiff("d", Date, "1/1/2015") >= 0 Then
    Worksheets("Sheet1").Range("A2").Value = Worksheets("Sheet1").Range("A2").Value + 100
End If
End Sub

If I misunderstand something, please feel free let me know.

Regards,

George Zhao
TechNet Community Support

Free Windows Admin Tool Kit Click here and download it now
March 18th, 2015 10:21pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics