<style></style>I have a cell that has a date in it. I would like that cell to automatically update with a new date once the date in it is reached. Is this possible?
Excel Facts
Which lookup functions find a value equal or greater than the lookup value?
Put this VBA code in the "ThisWorkbook" VB Module of that particular workbook.
Code:
Private Sub Workbook_Open()
Dim shName As String
Dim celAdd As String
Dim dateDiff As Long
' ***ENTER SHEET NAME TO APPLY TO***
shName = "Sheet3"
' ***ENTER CELL ADDRESS TO APPLY TO***
celAdd = "A1"
' Go to sheet
Sheets(shName).Activate
' Check date in cell
dateDiff = Date - Range(celAdd)
Do Until dateDiff < 14
Range(celAdd) = Range(celAdd) + 14
dateDiff = Date - Range(celAdd)
Loop
End Sub
Just change the sheet name and cell address variables at the top to match your needs.
We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel
Which adblocker are you using?
Disable AdBlock
Follow these easy steps to disable AdBlock
1)Click on the icon in the browser’s toolbar. 2)Click on the icon in the browser’s toolbar. 2)Click on the "Pause on this site" option.
Go back
Disable AdBlock Plus
Follow these easy steps to disable AdBlock Plus
1)Click on the icon in the browser’s toolbar. 2)Click on the toggle to disable it for "mrexcel.com".
Go back
Disable uBlock Origin
Follow these easy steps to disable uBlock Origin
1)Click on the icon in the browser’s toolbar. 2)Click on the "Power" button. 3)Click on the "Refresh" button.
Go back
Disable uBlock
Follow these easy steps to disable uBlock
1)Click on the icon in the browser’s toolbar. 2)Click on the "Power" button. 3)Click on the "Refresh" button.