Date + Time() problem

Dachande

Registered User.
Local time
Today, 09:49
Joined
Dec 15, 2000
Messages
16
Hello,

I am trying to add a date and time stamp to a field in a form once somebody clicks on a check box to say that the problem has been resolved.

This works fine if I start from scratch on a new form but when I try to add this to an existing form it adds the correct date in but a totally different time (about 10 hours in front).

Does anyone know why this could be happening? I have tried starting a new form and then copying across the code and controls but it still doesnt work.

Please find below the beginning of the code I have used:

Private Sub Closed_Click()
On Error GoTo ErrorLogon

Dim DTdate As Date
DTdate = Date


If Me.Closed = True Then
Me.Date_Ins = DTdate + Time()

Thanks for any help that is offered.

Mark
 
Mark,

A possible work around: use Now.

Me.Date_Ins = Now

Regards,
Tim
 
Thanks very much Tim that works great :)

Mark
 

Users who are viewing this thread

Back
Top Bottom