Dear Gents,
I have a time sheet application and trying to limit users to enter only 8 hours per day , if the value was more than 8 it shows pop up window " You can't enter more than 8 hours per day "
here is my code to solve this problem except that i can't specify the date
Code:
Private Sub Hours_AfterUpdate()
If Me.Hours.Value > 8 Then
Me.Add_Record.Enabled = False
MsgBox "You are trying to add more than 8 hours / Day , Please use overtime box if you are trying to add overtime hours", vbInformation
Else
Me.Add_Record.Enabled = True
End If
End Sub