Need to automatically update date in a date field when record info changes

S

Stacey

I have a date field in a form that I'm using that I want to
automatically update to the current date anytime I change
any
information in that record.
Therefore, if the original date I worked on a customer
record was
6/20/03 and I changed some information on 10/30/03, I
would want it to
change the date to 10/30/03. This way, the next time I
look at the
record I will be able to know when I last changed
information and
therefore how recent and accurate the record information
is. Does
anyone know how to do this? Someone told me a long time
ago, but I
have since lost the instructions and can't remember how.
Can anyone
help?
 
R

Rick Brandt

Stacey said:
I have a date field in a form that I'm using that I want to
automatically update to the current date anytime I change
any
information in that record.
Therefore, if the original date I worked on a customer
record was
6/20/03 and I changed some information on 10/30/03, I
would want it to
change the date to 10/30/03. This way, the next time I
look at the
record I will be able to know when I last changed
information and
therefore how recent and accurate the record information
is. Does
anyone know how to do this? Someone told me a long time
ago, but I
have since lost the instructions and can't remember how.
Can anyone
help?

Assuming a field name of RevisedOn...

In the BeforeUpdate event for the form have code similar to...

Me![RevisedOn] = Date() 'Date Only
or
Me![RevisedOn] = Now() 'Date and Time
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top