How to Record the Date a Specific Access Field Changes
Question details
The user needs to store the exact date or time when an individual field is modified in Microsoft Access, rather than updating a generic timestamp that triggers anytime any part of the record changes.

- Product
- Microsoft Access
- Device & OS
- not provided
- Scenario
- Tracking data modifications at the specific field level within Access forms to maintain an accurate audit trail.
- Observed behavior
- Currently, only the modification date of the entire record is captured, but the goal is to specifically isolate and capture the change date of a target field.
Ensure you have created a designated Date/Time field in your underlying table to store the timestamp, and remember that data should be edited through forms rather than directly in tables to allow VBA events to trigger.
Use BeforeUpdate and Current Events in VBA
This method compares the previous and current values of the field to accurately log when a change occurs, making it the most robust solution.
By leveraging the Form_Current event, you can store the original field value before the user makes any edits. Then, using the Form_BeforeUpdate event, you can compare the new value against the original. If they differ, the timestamp field is automatically updated.
Open your Access form in Design View. Right-click the form, select 'Build Event', and choose 'Code Builder' to open the VBA editor.
At the top of the form's code module, declare a variable to hold the original value (e.g., Private strOriginalValue As String).
In the Form_Current event, capture the existing value. Use the Nz function to handle nulls: strOriginalValue = Nz(Me.YourTargetField, "").
In the Form_BeforeUpdate event, write an IF statement: If Me.YourTargetField <> strOriginalValue Then Me.YourDateField = VBA.Date.
Save the VBA code, return to Form View, and modify the target field to ensure the date field populates correctly.

Use the Control's AfterUpdate Event
A simpler approach that updates the timestamp immediately after a specific control on the form is modified by the user.
Looking for a Lightweight Office Suite?
While Microsoft Access handles complex database management, everyday tasks like document editing, spreadsheet analysis, and presentations require an efficient office suite. WPS Office offers a free, lightweight, and highly compatible alternative for your daily productivity needs.
- 1. Download the Installer: Visit the official WPS Office website and click the free download button.
- 2. Install WPS Office: Run the downloaded executable file and follow the quick setup wizard.
- 3. Start Creating: Open WPS Writer, Spreadsheet, or Presentation to immediately start working with your existing Microsoft Office files.

Frequently Asked Questions
Why isn't my Date field updating when I change the data in the Access table directly?
VBA events like BeforeUpdate and AfterUpdate are tied strictly to Access Forms. If you open a table and edit the raw data directly, these form-level events will not trigger. It is highly recommended to perform all data modifications through forms to ensure audit trails and validations work correctly.
What is the difference between VBA.Date and Now() in Access?
VBA.Date returns only the current system date without any time component (e.g., 10/24/2023). Now() returns both the current system date and the exact time (e.g., 10/24/2023 2:45 PM). Choose Now() if your database requires tracking the specific hour and minute a field was altered.
How do I handle errors when a previously empty field is updated?
Comparing an empty (null) field to a new text string can cause VBA errors. You should use the Nz() function to convert null values to an empty string ("") or a zero before comparing them. For example, 'Nz(Me.FieldName, "")' ensures smooth comparisons.




