Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Now Date Formula
In cell A5 I have the following formula =IF(B5="","",NOW())
which allows me to enter something into cell B5 and then the date fills in automatically. What I need is make it so the date doesn't change in A5, when I go into the spreadsheet again. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Now Date Formula
You need VBA for this
Private Sub Worksheet_Change(ByVal Target As Range) On Error GoTo ws_exit: Application.EnableEvents = False If Not Intersect(Target, Me.Range("A5")) Is Nothing Then With Target If .Offset(0, 10).Value = "" Then .Value = "" Else .Value = Format(Date, "dd mmm yyyy") End With End With End If ws_exit: Application.EnableEvents = True End Sub 'This is worksheet event code, which means that it needs to be 'placed in the appropriate worksheet code module, not a standard 'code module. To do this, right-click on the sheet tab, select 'the View Code option from the menu, and paste the code in. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Jodi" wrote in message ... In cell A5 I have the following formula =IF(B5="","",NOW()) which allows me to enter something into cell B5 and then the date fills in automatically. What I need is make it so the date doesn't change in A5, when I go into the spreadsheet again. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
formula to look at current date and markdown date to give price | Excel Discussion (Misc queries) | |||
Create a formula in a date range to locate a specific date - ecel | Excel Discussion (Misc queries) | |||
Excel Formula to calulate number of days passed from date to date | Excel Discussion (Misc queries) | |||
Formula for determining if two date columns fall within specific date range | Excel Worksheet Functions | |||
Formula for determining if two date columns fall within specific date range | Excel Discussion (Misc queries) |