If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Time/Date Stamp for Row Modified
I need a way of including a Time/Date stamp with each record. The Time/Date
would be updated each time the row's data is modified, rather it be via. a form, an update query, an open view, etc. Can this be accomplished with a validation function or some other automatic method? Help is necessary. Thanks in advance. |
#2
|
|||
|
|||
Time/Date Stamp for Row Modified
On Mon, 12 Dec 2005 20:26:02 -0800, "sm"
wrote: I need a way of including a Time/Date stamp with each record. The Time/Date would be updated each time the row's data is modified, rather it be via. a form, an update query, an open view, etc. Can this be accomplished with a validation function or some other automatic method? Help is necessary. Thanks in advance. With the current version of Access... only if you do the update using a Form. Tables don't have any usable events. You can store the data in MSDE or SQL Server Express, link to it from Access, and use Table Triggers to store a timestamp - but in Access, all you can do is use a Form, and put code in the form's BeforeUpdate event: Private Sub Form_BeforeUpdate(Cancel as Integer) any record validation code goes here if the record is invalid set Cancel to True ELSE Me!txtTimestamp = Now End If End Sub where txtTimestamp is a textbox bound to the date/time Timestamp field. John W. Vinson[MVP] |
#3
|
|||
|
|||
Time/Date Stamp for Row Modified
John, Is there no other way to do it through validation rules, input filters,
smart tags, anything? Thanks for the quick response. sm "John Vinson" wrote: On Mon, 12 Dec 2005 20:26:02 -0800, "sm" wrote: I need a way of including a Time/Date stamp with each record. The Time/Date would be updated each time the row's data is modified, rather it be via. a form, an update query, an open view, etc. Can this be accomplished with a validation function or some other automatic method? Help is necessary. Thanks in advance. With the current version of Access... only if you do the update using a Form. Tables don't have any usable events. You can store the data in MSDE or SQL Server Express, link to it from Access, and use Table Triggers to store a timestamp - but in Access, all you can do is use a Form, and put code in the form's BeforeUpdate event: Private Sub Form_BeforeUpdate(Cancel as Integer) any record validation code goes here if the record is invalid set Cancel to True ELSE Me!txtTimestamp = Now End If End Sub where txtTimestamp is a textbox bound to the date/time Timestamp field. John W. Vinson[MVP] |
#4
|
|||
|
|||
Time/Date Stamp for Row Modified
On Mon, 12 Dec 2005 21:43:02 -0800, "sm"
wrote: John, Is there no other way to do it through validation rules, input filters, smart tags, anything? In a JET Table? Not to my knowledge. In a SQL Server table (which you can use, free - MSDE or SQL Server Express) you can use table triggers, but they're not yet available in Access. John W. Vinson[MVP] |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Can I time/date stamp a read-only section of a Word document? | Jan W., Chicago | General Discussion | 1 | October 29th, 2005 04:00 AM |
Date/Time stamp of new & modified records | Darrell | New Users | 8 | August 12th, 2005 02:19 AM |
Date and time stamp a field (not record) when it is modified | KB | General Discussion | 2 | May 18th, 2005 06:01 AM |
1. time/date stamp as key & 2. total'g, av'g minutes & seconds | gcp | New Users | 2 | July 13th, 2004 02:21 AM |
time/date stamp | Mike_Hiler | Worksheet Functions | 2 | March 17th, 2004 07:39 PM |