Saving Date and Time

F

fiona.innes

Hi,

I have a form called frmDetails and I have set a text box (txtDate) in
the form with the control source of =Format(Now(),"dddd"", ""mmm d
yyyy"", ""hh:nn:ss ampm") but the problem is I want this Time & Date
to be recorded in the table (called tblDetails) as it needs to be used
for referancing when entries were entered into the database.
Can anyone tell me how to do this.

Thanks

Fiona
 
A

Al Campagna

Fiona,
Add a Date/Time field to your table. (ex. DTNow)
Add that field to your form.
On your form, make the Default Value for that field...
(assuming your calculation is correct, and I think it is)

=Format(Now(),"dddd"", ""mmm d yyyy"", ""hh:nn:ss ampm")

Whenever a new record is created, the Default calculation will set the
value of DTNow.
--
hth
Al Campagna
Microsoft Access MVP
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."
 
Top