D
Dean
I have a form i need to add code to but am not real
familer with VB. What I have is a db for that lets
employees sign up for vacation. The form allows them to
sign up for days and also delete days. We recently
decided that we do not want them to delete vacation days 2
weeks or less before the first day of vac. What I have so
far is
If strLOCK_IN_FLAG = "Y" Then
Call check_LockIn
EndIf
then:
Private Sub check_LockIn()
Dim NoChange As String
Dim dtmREQUEST_DATE As Date
NoChange = Date - 14
If dtmREQUEST_DATE <= NoChange Then
MsgBox _
"You cannot delete vacation days that are
locked in this close to the first day of vaction." &
vbCrLf & vbCrLf & _
"Please contact your supervisor for help with
this."
Else
End If
End Sub
i think my date formula is wrong, it gives the above
message for all deletion trys.
Any suggestions/ideas/code would be appreciated
Thanks
Dean
familer with VB. What I have is a db for that lets
employees sign up for vacation. The form allows them to
sign up for days and also delete days. We recently
decided that we do not want them to delete vacation days 2
weeks or less before the first day of vac. What I have so
far is
If strLOCK_IN_FLAG = "Y" Then
Call check_LockIn
EndIf
then:
Private Sub check_LockIn()
Dim NoChange As String
Dim dtmREQUEST_DATE As Date
NoChange = Date - 14
If dtmREQUEST_DATE <= NoChange Then
MsgBox _
"You cannot delete vacation days that are
locked in this close to the first day of vaction." &
vbCrLf & vbCrLf & _
"Please contact your supervisor for help with
this."
Else
End If
End Sub
i think my date formula is wrong, it gives the above
message for all deletion trys.
Any suggestions/ideas/code would be appreciated
Thanks
Dean