Auto static date fill

SPVM

New Member
Joined
Jan 14, 2021
Messages
10
Office Version
  1. 365
Platform
  1. Windows
Hi

Please assist.

I have 5 different values available from a drop down menu for column A. ( To Start, In Progress, Complete, Delayed, Postponed.) When a value is chosen for that cell in column A, I need that days date to be filled in, in column B.
The date when the cell was updated and that date will be static, it must not move on. (The same formulae will run down the rows in the spread sheet. A3-A10 and B3-B10)

Please assist
Cheers
 

Some videos you may like

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
48,374
Office Version
  1. 365
Platform
  1. Windows
The same formulae will run down the rows in the spread sheet. A3-A10 and B3-B10)
This sort of thing does not lend itself to formulas as they will update as the date changes. Try this Worksheet_Change event vba code with a copy of your workbook. To implement ..
1. Right click the sheet name tab and choose "View Code".
2. Copy and Paste the code below into the main right hand pane that opens at step 1.
3. Close the Visual Basic window & test.
4. Your workbook will need to be saved as a macro-enabled workbook (*.xlsm).

VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
  Dim Changed As Range, Cell As Range
 
  Set Changed = Intersect(Target, Range("A3:A10"))
  If Not Changed Is Nothing Then
    Application.EnableEvents = False
    For Each Cell In Changed
      Cell.Offset(, 1).Value = Date
    Next Cell
    Application.EnableEvents = True
  End If
End Sub
 

Watch MrExcel Video

Forum statistics

Threads
1,127,113
Messages
5,622,808
Members
415,933
Latest member
Dlegend_79

We've detected that you are using an adblocker.

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.
Go back
Top