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
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