ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How do I show file creation date in a cell in Excel? (https://www.excelbanter.com/excel-worksheet-functions/60385-how-do-i-show-file-creation-date-cell-excel.html)

Eddie Armstrong

How do I show file creation date in a cell in Excel?
 
I need to have a field on a worksheet to show the file creation date. It
can't be in the header or footer as I need to make calculations based on it.
Any clues?

Regards,
Eddie

Bob Phillips

How do I show file creation date in a cell in Excel?
 

'-----------------------------------------------------------------
Function DocProps(prop As String)
'-----------------------------------------------------------------
Application.Volatile
On Error GoTo err_value
DocProps = ActiveWorkbook.BuiltinDocument*Properties _
(prop)
Exit Function
err_value:
DocProps = CVErr(xlErrValue)
End Function


and enter in a cell such as
=DocProps ("last save time")


--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Eddie Armstrong" <Eddie wrote in
message ...
I need to have a field on a worksheet to show the file creation date. It
can't be in the header or footer as I need to make calculations based on

it.
Any clues?

Regards,
Eddie




Louise

How do I show file creation date in a cell in Excel?
 
Hi Eddie

Does this help......

Insert a static date or time
Current date Select a cell and press CTRL+;

Current time Select a cell and press CTRL+SHIFT+;

Current date and time Select a cell and press CTRL+; then SPACE then
CTRL+SHIFT+;

Louise

"Eddie Armstrong" wrote:

I need to have a field on a worksheet to show the file creation date. It
can't be in the header or footer as I need to make calculations based on it.
Any clues?

Regards,
Eddie


CLR

How do I show file creation date in a cell in Excel?
 
This line of code in an appropriate macro will do it............

Range("b1") = ActiveWorkbook.BuiltinDocumentProperties("Creation Date")

Vaya con Dios,
Chuck, CABGx3



"Eddie Armstrong" wrote:

I need to have a field on a worksheet to show the file creation date. It
can't be in the header or footer as I need to make calculations based on it.
Any clues?

Regards,
Eddie


Duke Carey

How do I show file creation date in a cell in Excel?
 
The creation date is part of the workbook's builtin document properties and
can be accessed via VBA

thisworkbook.BuiltinDocumentProperties("Creation Date")



"Eddie Armstrong" wrote:

I need to have a field on a worksheet to show the file creation date. It
can't be in the header or footer as I need to make calculations based on it.
Any clues?

Regards,
Eddie


Gord Dibben

How do I show file creation date in a cell in Excel?
 
Should be........

=DocProps("creation date")

or use this UDF, although I prefer Bob's because it is not specific to one
property.

Function CreaDate() As Date
CreaDate = ActiveWorkbook.BuiltinDocumentProperties("Creation Date")
End Function


Gord Dibben Excel MVP


On Wed, 14 Dec 2005 16:35:13 -0000, "Bob Phillips"
wrote:


'-----------------------------------------------------------------
Function DocProps(prop As String)
'-----------------------------------------------------------------
Application.Volatile
On Error GoTo err_value
DocProps = ActiveWorkbook.BuiltinDocument*Properties _
(prop)
Exit Function
err_value:
DocProps = CVErr(xlErrValue)
End Function


and enter in a cell such as
=DocProps ("last save time")


Bob Phillips

How do I show file creation date in a cell in Excel?
 
Thanks Gord, force of habit as most ask for last saved.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
Should be........

=DocProps("creation date")

or use this UDF, although I prefer Bob's because it is not specific to one
property.

Function CreaDate() As Date
CreaDate = ActiveWorkbook.BuiltinDocumentProperties("Creation Date")
End Function


Gord Dibben Excel MVP


On Wed, 14 Dec 2005 16:35:13 -0000, "Bob Phillips"
wrote:


'-----------------------------------------------------------------
Function DocProps(prop As String)
'-----------------------------------------------------------------
Application.Volatile
On Error GoTo err_value
DocProps = ActiveWorkbook.BuiltinDocument*Properties _
(prop)
Exit Function
err_value:
DocProps = CVErr(xlErrValue)
End Function


and enter in a cell such as
=DocProps ("last save time")




Gord Dibben

How do I show file creation date in a cell in Excel?
 
Creation Date gets very little call.


Gord

On Wed, 14 Dec 2005 19:26:08 -0000, "Bob Phillips"
wrote:

Thanks Gord, force of habit as most ask for last saved.



All times are GMT +1. The time now is 09:50 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com