A Microsoft Office (Excel, Word) forum. OfficeFrustration

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.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Adding an automatic datestamp to a record



 
 
Thread Tools Display Modes
  #1  
Old August 29th, 2005, 06:52 AM
Paul M
external usenet poster
 
Posts: n/a
Default Adding an automatic datestamp to a record

In my form I have a date field called "updated". I want to automatically
update this field with the current date whenever any of the data in that
record changes. Can someone explain how to set up the properties to do this.
I think I use the "After Update" property in the form but I can't get it to
work. Thanks in advance.

-Paul
  #2  
Old August 29th, 2005, 08:22 AM
Ofer
external usenet poster
 
Posts: n/a
Default

Add the DateField To the form, if didn't already do that.
On the before update event of the form add the code

Me.DateFieldName = Date()

The problem with this code, if a user change the data in one of the fields,
and then change it back to the prev value, the before update event will still
run


"Paul M" wrote:

In my form I have a date field called "updated". I want to automatically
update this field with the current date whenever any of the data in that
record changes. Can someone explain how to set up the properties to do this.
I think I use the "After Update" property in the form but I can't get it to
work. Thanks in advance.

-Paul

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating Records in tables automatically peterg290935 Using Forms 8 June 22nd, 2005 08:12 AM
adding record to two tables kmhnhsuk Using Forms 5 June 13th, 2005 03:21 PM
Adding Record with Time Stamp James Fillmore via AccessMonster.com Using Forms 1 February 21st, 2005 09:00 AM
Adding a Record to the Database Out of Sequential Order Lisa General Discussion 3 September 29th, 2004 04:59 PM
Adding a Record to a Form Out of Order Lisa Using Forms 3 September 29th, 2004 04:46 PM


All times are GMT +1. The time now is 02:42 PM.


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