Today()

  • Thread starter Thread starter Richard Toller
  • Start date Start date
R

Richard Toller

I'm trying to get the current date entered automatically in a shee
that is used to record orders. One row is used for each order and th
current date is required in column J for each order.

Is there any way to use TODAY() Function, so that it records
today's date via formula, but does not change the order dates entere
on previous days?

Appreciate any help on this one.
Thanks,
Ric
 
Richard,

Just hit the Ctrl-; key?

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

Richard Toller said:
I'm trying to get the current date entered automatically in a sheet
that is used to record orders. One row is used for each order and the
current date is required in column J for each order.

Is there any way to use TODAY() Function, so that it records
today's date via formula, but does not change the order dates entered
on previous days?

Appreciate any help on this one.
Thanks,
Rich


------------------------------------------------



~~Now Available: Financial Statements.xls, a step by step guide to
creating financial statements
 
Richard

Automatic = VBA

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
'when entering data in a cell in Col I
On Error GoTo enditall
If Target.Cells.Column < 10 Then
n = Target.Row
If Excel.Range("I" & n).Value <> "" Then
Excel.Range("J" & n).Value = Now
End If
End If
enditall:
End Sub

The code assumes that cell in column I would be last cell to be filled when
doing up orders. Adjust to suit.

To use, right-click on sheet tab and "View code". Copy/paste code in there.

Gord Dibben XL2002
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

today's date static 1
Macro for Dates 5
VBA Go to Today's Date 4
Copy a Range that matches Todays date Q 7
Count Dates in a range 2
Today's Date 1
Access Property sheet data missing also syntax 0
Index on another worksheet 5

Back
Top