date modified for a form using subforms

  • Thread starter Thread starter Tansy
  • Start date Start date
T

Tansy

I'm pretty new to Access. I saw some things posted on this list that
looked like they might almost answer my question, but there was
something I was missing.

I have a form based on a table. The form has three subforms in it. I
created a Date Modified tag for when info is updated in the main
table, but I want a Date Modified expression for when the the main
form OR the subforms are updated. Is this possible?

Thanks
 
Tansy,

You can use the Dirty event of the main form and each subform to assign the
date (& optionally, the time). From the main form:

Me![YourLastChangedControl] = Date()

From the subforms,

Me.Parent.Form![YourLastChangedControl] = Date()

To record the time as well, replace the Date() function call to Now().

Hope that helps.
Sprinks
 

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

Back
Top