Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Old February 5th 07, 04:38 AM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Feb 2007
Posts: 8
Default I want to insert the file properties into a cell for printing.

How can I retrieve file properties for printing in Excel spread sheets?

  #2   Report Post  
Old February 5th 07, 04:59 PM posted to microsoft.public.excel.misc
external usenet poster
 
First recorded activity by ExcelBanter: Jul 2006
Posts: 22,909
Default I want to insert the file properties into a cell for printing.

First off.........save a backup of your workbook.

Then use this User Defined Function

Function DocProps(prop As String)
Application.Volatile
On Error GoTo err_value
DocProps = ActiveWorkbook.BuiltinDocumentProperties _
(prop)
Exit Function
err_value:
DocProps = CVErr(xlErrValue)
End Function

'=DOCPROPS("last author")
'or
'=DOCPROPS("last save time")
'or
'DOCPROPS("creation date")

For a list of other properties that may be available(not all are), run this
macro.

Sub props()
rw = 1
Worksheets.Add
For Each p In ActiveWorkbook.BuiltinDocumentProperties
Cells(rw, 1).Value = p.Name
rw = rw + 1
Next
End Sub


Gord Dibben MS Excel MVP

On Sun, 4 Feb 2007 20:38:00 -0800, Felicity
wrote:

How can I retrieve file properties for printing in Excel spread sheets?




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cell References [email protected] Excel Discussion (Misc queries) 2 November 15th 06 11:37 PM
Insert document properties in a cell oldsambvca Excel Worksheet Functions 0 June 26th 06 09:50 PM
excel cell lookup file on harddrive dj_siek Excel Discussion (Misc queries) 4 February 8th 06 12:09 AM
Possible Lookup Table Karen Excel Worksheet Functions 5 June 8th 05 09:43 PM
Using Jet to read excel file returns blank for last cell - sometim Ron Excel Discussion (Misc queries) 1 December 9th 04 08:21 AM


All times are GMT +1. The time now is 07:53 PM.

Powered by vBulletin® Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright 2004-2017 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"

 

Copyright © 2017