Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
It is probably elementary but I am no expert:
Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Inserted where?
Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Tim
Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Cells(rw,col).value=Now
where rw & col are variables defining the row and column numbers where you want the date to go. be sure to formate the cell (in code) to display date and time the way you want -- steveB Remove "AYN" from email to respond "MikeA" wrote in message ... Tim Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Mike,
All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. To access this programatically (via VBA), check out the BuiltinDocumentProperties collection of the Workbook object in Excel's help. A number of properties are available, the one you're probably most interested in is "Last Save Time". As an example, with a previously saved workbook open, paste and execute this code into the Immediate pane of the Visual Basic Editor (VBE). debug.Print ActiveWorkbook.BuiltinDocumentProperties("Last Save Time") Hit enter and you'll get the date and time this workbook was last saved. e.g. 01-Jul-05 19:06:12 You can use the properties in this collection to (programatically) set cell values, or page headers/footers (or whatever). HTH, Sean. "MikeA" wrote: Tim Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Not to detract from your excellent advice, but just to add:
All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. Isn't totally correct. This was not supported in Excel until xl2000. For example, in a workbook that has only been opened in Excel 97 or earlier and if executed in xl97, your code produces an error. -- Regards, Tom Ogilvy "Sean Connolly" wrote in message ... Hi Mike, All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. To access this programatically (via VBA), check out the BuiltinDocumentProperties collection of the Workbook object in Excel's help. A number of properties are available, the one you're probably most interested in is "Last Save Time". As an example, with a previously saved workbook open, paste and execute this code into the Immediate pane of the Visual Basic Editor (VBE). debug.Print ActiveWorkbook.BuiltinDocumentProperties("Last Save Time") Hit enter and you'll get the date and time this workbook was last saved. e.g. 01-Jul-05 19:06:12 You can use the properties in this collection to (programatically) set cell values, or page headers/footers (or whatever). HTH, Sean. "MikeA" wrote: Tim Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Tom,
Of course you're correct, this collection hasn't been available in Excel 'forever', but ... On an old PC of mine I have Excel 97 SR-1 (exactly for testing such situations <g!) and the code works just fine and dandy. I'm intrigued now ... Cheers, Sean. "Tom Ogilvy" wrote: Not to detract from your excellent advice, but just to add: All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. Isn't totally correct. This was not supported in Excel until xl2000. For example, in a workbook that has only been opened in Excel 97 or earlier and if executed in xl97, your code produces an error. -- Regards, Tom Ogilvy "Sean Connolly" wrote in message ... Hi Mike, All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. To access this programatically (via VBA), check out the BuiltinDocumentProperties collection of the Workbook object in Excel's help. A number of properties are available, the one you're probably most interested in is "Last Save Time". As an example, with a previously saved workbook open, paste and execute this code into the Immediate pane of the Visual Basic Editor (VBE). debug.Print ActiveWorkbook.BuiltinDocumentProperties("Last Save Time") Hit enter and you'll get the date and time this workbook was last saved. e.g. 01-Jul-05 19:06:12 You can use the properties in this collection to (programatically) set cell values, or page headers/footers (or whatever). HTH, Sean. "MikeA" wrote: Tim Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
#8
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You created the file in xl97 and it has never been used in a later version?
Try it in a new file. I had no problem raising the error. -- Regards, Tom Ogilvy "Sean Connolly" wrote in message ... Hi Tom, Of course you're correct, this collection hasn't been available in Excel 'forever', but ... On an old PC of mine I have Excel 97 SR-1 (exactly for testing such situations <g!) and the code works just fine and dandy. I'm intrigued now ... Cheers, Sean. "Tom Ogilvy" wrote: Not to detract from your excellent advice, but just to add: All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. Isn't totally correct. This was not supported in Excel until xl2000. For example, in a workbook that has only been opened in Excel 97 or earlier and if executed in xl97, your code produces an error. -- Regards, Tom Ogilvy "Sean Connolly" wrote in message ... Hi Mike, All Excel workbooks are saved with a datetimestamp as standard built-in Excel functionality. To access this programatically (via VBA), check out the BuiltinDocumentProperties collection of the Workbook object in Excel's help. A number of properties are available, the one you're probably most interested in is "Last Save Time". As an example, with a previously saved workbook open, paste and execute this code into the Immediate pane of the Visual Basic Editor (VBE). debug.Print ActiveWorkbook.BuiltinDocumentProperties("Last Save Time") Hit enter and you'll get the date and time this workbook was last saved. e.g. 01-Jul-05 19:06:12 You can use the properties in this collection to (programatically) set cell values, or page headers/footers (or whatever). HTH, Sean. "MikeA" wrote: Tim Say at the bottom of the page - either side. The idea is that a spread sheet will not be saved without a date stamp. Mike A "Tim Williams" <saxifrax@pacbell*dot*net wrote in message ... Inserted where? Tim "MikeA" wrote in message ... It is probably elementary but I am no expert: Is it possible to set up Excel in such a way that the date (and time) will always be inserted on Save? Thanks MikeA |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Automatically insert date | Excel Worksheet Functions | |||
insert DATE automatically | Excel Discussion (Misc queries) | |||
Insert date automatically | Excel Discussion (Misc queries) | |||
Automatically Insert DATE, so that DATE will NOT change | Excel Worksheet Functions | |||
Insert date automatically | Excel Discussion (Misc queries) |