Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default want to record date for each time I update a file - Excel 2007

I want to keep track of dates that a file is updated.
The Summary only shows the last time a file was modified but I want to keep
track of each time it is modified.
Is there a way to do this?
I have MS Office Enterprise 2007.
Thanks
Patty

--
You can always teach an old dog new tricks.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 915
Default want to record date for each time I update a file - Excel 2007

PattyR wrote:
I want to keep track of dates that a file is updated.
The Summary only shows the last time a file was modified but I want to keep
track of each time it is modified.
Is there a way to do this?
I have MS Office Enterprise 2007.
Thanks
Patty


I dug up this code (can't recall where I got the original idea). The
functionality here is a save event will silently capture the user and
timestamp, and write the aforementioned to a worksheet called "SAVE"
(which you must create in the workbook beforehand, and hide if desired).

I can upload a workbook that demonstrates this if you like.

Watch for line-wrap:

THISWORKBOOK.CODE

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Dim lastrow As Range
Static IgnoreSave As Boolean

If Not IgnoreSave Then
With ThisWorkbook
With Worksheets("SAVE")
Set lastrow = .Cells(Rows.Count, 1).End(xlUp) _
.Offset(1, 0)
lastrow.Value = "Saved By " _
& Environ("UserName") & " " & Now
End With
IgnoreSave = True
.Save
IgnoreSave = False
End With
End If
End Sub

END CODE<<
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default want to record date for each time I update a file - Excel 2007


PattyR wrote:
I want to keep track of dates that a file is updated.
The Summary only shows the last time a file was modified but I want to keep
track of each time it is modified.
Is there a way to do this?
I have MS Office Enterprise 2007.
Thanks
Patty


I dug up this code (can't recall where I got the original idea). The
functionality here is a save event will silently capture the user and
timestamp, and write the aforementioned to a worksheet called "SAVE"
(which you must create in the workbook beforehand, and hide if desired).

I can upload a workbook that demonstrates this if you like.

Watch for line-wrap:

THISWORKBOOK.CODE

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Dim lastrow As Range
Static IgnoreSave As Boolean

If Not IgnoreSave Then
With ThisWorkbook
With Worksheets("SAVE")
Set lastrow = .Cells(Rows.Count, 1).End(xlUp) _
.Offset(1, 0)
lastrow.Value = "Saved By " _
& Environ("UserName") & " " & Now
End With
IgnoreSave = True
.Save
IgnoreSave = False
End With
End If
End Sub

END CODE<<


Hi
Could you please tell me where to enter the code? I've never dealth with
macros in Excel before.
Thanks
Patty
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
Excel 2003 file/properties to view created date/time how in 2007? Bald Eagle Boy Excel Discussion (Misc queries) 2 June 27th 12 09:11 PM
want to record date for each time I update a file PattyR Excel Discussion (Misc queries) 2 May 27th 09 05:40 AM
Excel 2007 protected file corrupt after update chris l Excel Discussion (Misc queries) 4 January 3rd 08 11:41 PM
How to automatically update the date any time the Excel is openned DORI Excel Worksheet Functions 2 November 21st 05 05:06 AM
How do you continuously update time and date in an Excel cell? engine99 Excel Worksheet Functions 7 February 21st 05 02:20 AM


All times are GMT +1. The time now is 06:29 PM.

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

About Us

"It's about Microsoft Excel"