I need to store the date a record was created, automatically.

S

Stefan Hoffmann

hi,

I need to store the date and time a record was created, automatically.
This is not possible, but you can store the date and time when a record
is created using the forms Before Insert event:

Private Sub Form_BeforeInsert(Cancel As Integer)

Me![CreatedAt] = Now()

End Sub


mfG
--> stefan <--
 
G

golfinray

Add a field to your table called Last_Updated. Add a textbox to your form.
Make the controlsource Last_Updated. Go to the afterupdate property of the
field you want to record and add:
Me.last_updated=now()
 

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