![]() |
insert current date
Hi,
I am trying to do what I suspect is a simple task and probably making a meal out of it. All I want to do is insert the current date into a cell, other than having to type it. I recorded a macro; it has one line in it ActiveCell.FormulaR1C1 = "=TODAY()" unfortunately every time I use the macro the previous dates are set to today's date. Not surprising really when the today() function is used. I want to insert the date and then have it 'fixed'. How can I do this please? Thanks -- Nospam |
insert current date
Sub FixDate()
ActiveCell.Value = Date End Sub somethinglikeant Nospam wrote: Hi, I am trying to do what I suspect is a simple task and probably making a meal out of it. All I want to do is insert the current date into a cell, other than having to type it. I recorded a macro; it has one line in it ActiveCell.FormulaR1C1 = "=TODAY()" unfortunately every time I use the macro the previous dates are set to today's date. Not surprising really when the today() function is used. I want to insert the date and then have it 'fixed'. How can I do this please? Thanks -- Nospam |
insert current date
Hi Nospam
Ctrl ; insert the date Or with code ActiveCell.Value = Format(Date, "dd-mmm-yyyy") -- Regards Ron de Bruin http://www.rondebruin.nl "Nospam" wrote in message ... Hi, I am trying to do what I suspect is a simple task and probably making a meal out of it. All I want to do is insert the current date into a cell, other than having to type it. I recorded a macro; it has one line in it ActiveCell.FormulaR1C1 = "=TODAY()" unfortunately every time I use the macro the previous dates are set to today's date. Not surprising really when the today() function is used. I want to insert the date and then have it 'fixed'. How can I do this please? Thanks -- Nospam |
insert current date
In message , Ron de Bruin
writes Hi Nospam Ctrl ; insert the date Or with code ActiveCell.Value = Format(Date, "dd-mmm-yyyy") Thanks that did the trick -- Nospam |
insert current date
Thanks
In message .com, somethinglikeant writes Sub FixDate() ActiveCell.Value = Date End Sub somethinglikeant Nospam wrote: Hi, I am trying to do what I suspect is a simple task and probably making a meal out of it. All I want to do is insert the current date into a cell, other than having to type it. I recorded a macro; it has one line in it ActiveCell.FormulaR1C1 = "=TODAY()" unfortunately every time I use the macro the previous dates are set to today's date. Not surprising really when the today() function is used. I want to insert the date and then have it 'fixed'. How can I do this please? Thanks -- Nospam -- Nospam |
All times are GMT +1. The time now is 06:03 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com