Last Modified Date in ACCESS

luvbite38

Active Member
Joined
Jun 25, 2008
Messages
368
Hi,

I have a table and a field called Last Modified Date. I want somehow to automatically update the if value changes in that row.

Example

ID Fruits Last Modified Date
1 Apple 17/10/2010
2 Apple 17/10/2010
3 Apple 17/10/2010
4 Apple 17/10/2010
5 Apple 17/10/2010
6 Apple 17/10/2010

If someone makes some change Apple to Banana in second row on 18/10/2010 and changes Apple to Pineapple to 5th entry on 19/10/2010, the last modified Date changes should automatically change to 18/10/2010 against ID 2 and 19/10/2010 against 5th ID and Table should look like as follow

ID Fruits Last Modified Date
1 Apple 17/10/2010
2 Banana 18/10/2010
3 Apple 17/10/2010
4 Apple 17/10/2010
5 Pineapple 19/10/2010
6 Apple 17/10/2010

I am using Access 2010 and the changes will NOT be made on form. User will go into table to change anything.

Any suggestions pls..... I dunt knw if I need an event which triggers if value changes, update the date to NOW()) or something.

Thanks in advance.

Kindest ever Regards,
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
I am using Access 2010 and the changes will NOT be made on form. User will go into table to change anything.
This is generally a very bad idea. It is generally considered bad database design to have users update the underlying tables directly. There is too much potential for bad things to happen. Well designed databases are usually Form driven, where you can control exactly what the users can see and do to your data.

Using Forms, you can place Event Triggers that automatically run VBA code when the users update something, like you want. I do not know a way to do that if they update the tables directly. I do not even know if it is possible. Even if it is, it probably isn't nearly as easy as it to do using Forms.
 
Upvote 0
I agree with Joe. Build forms for your interface.
However, you can create a Data Macro in 2010 that will update a field when the record changes.
Advantages: It will run wherever that data is updated (form, query, table)
Disadvantage: Not compatible with any earlier version.

Denis
 
Upvote 0
However, you can create a Data Macro in 2010 that will update a field when the record changes.
That's pretty cool new feature!
I haven't seen much of Access 2010 yet.
 
Upvote 0
Thanks a million for your feedback.

I can completely understand where you coming from. Actually I am updating someone else's database and she asked me to stick to this format.... Do you by any chance know how to write the macro in 2010 to do the job for me pls.......

All your feedback is much much much appreciated.
 
Upvote 0

Forum statistics

Threads
1,217,346
Messages
6,136,042
Members
449,981
Latest member
kjd513

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top