Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to write todays date in an autoexec function
I run an auto exec macro that updates a report and I want to add the
day the report was updated in a cell in the report. So I just need to tack on a few lines of code that write todays date in a cell on the bookings tab, in cell L1. If this only writes when the autoexec macro runs it shouldn't replace the date if the macro hasn't run... is this assumption correct? Thanks for the help, Paul |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to write todays date in an autoexec function
Range("L1").FormulaR1C1 = "=Today()"
-- If this posting was helpful, please click on the Yes button. Regards, Michael Arch. "Paul Lambson" wrote: I run an auto exec macro that updates a report and I want to add the day the report was updated in a cell in the report. So I just need to tack on a few lines of code that write todays date in a cell on the bookings tab, in cell L1. If this only writes when the autoexec macro runs it shouldn't replace the date if the macro hasn't run... is this assumption correct? Thanks for the help, Paul |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to write todays date in an autoexec function
hi
sheets("Bookings").range("L1")= Date if Bookings is the active sheet while the macro is running then you might get away with Range("L1") = Date this code willl produce a static date of the date the macro was run and will remain unchanged untill the macro is run again or the date changed manually. Regards FSt1 "Paul Lambson" wrote: I run an auto exec macro that updates a report and I want to add the day the report was updated in a cell in the report. So I just need to tack on a few lines of code that write todays date in a cell on the bookings tab, in cell L1. If this only writes when the autoexec macro runs it shouldn't replace the date if the macro hasn't run... is this assumption correct? Thanks for the help, Paul |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Exel increment date problem wrt todays date. | Excel Worksheet Functions | |||
how can I return todays date (today() ) in an if function | Excel Worksheet Functions | |||
Create a button that will date stamp todays date in a cell | Excel Discussion (Misc queries) | |||
When I open my past invoice it keeps changing date to todays date | Excel Worksheet Functions | |||
How do I filter a list using a greater than todays date function? | Excel Worksheet Functions |