Buddy,
No reason that shouldn't work. Is it not working on say chart sheets, or on
worksheets?
would only do it for the activesheet myself
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
Activesheet.PageSetup.RightFooter = "&8Last Saved : " & _
ThisWorkbook.BuiltinDocumentProperties("Last Save Time")
End Sub
saves doing all sheets every time.
To put it in a cell use
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
For Each wkSht In ThisWorkbook.Worksheets
wkSht.Range("A1").Value = "&8Last Saved : " & _
ThisWorkbook.BuiltinDocumentProperties("Last Save Time")
Next wkSht
End Sub
or
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
Activesheet.Range("A1").Value = "&8Last Saved : " & _
ThisWorkbook.BuiltinDocumentProperties("Last Save Time")
End Sub
or even put the loop code in a standard macro.
--
HTH
RP
(remove nothere from the email address if mailing direct)
"buddys" wrote in message
...
Ok, I have been working on this for a while. I got some sheets to work
but
others don't. This is how I am doing it.
Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
For Each wkSht In ThisWorkbook.Worksheets
wkSht.PageSetup.RightFooter = "&8Last Saved : " & _
ThisWorkbook.BuiltinDocumentProperties("Last Save Time")
Next wkSht
End Sub
But on some sheets, It dosen't work. Also is there a way of putting it
into
a certin cell and not the footer?
Thanks,
Buddy
|