Hi Adam,
Thanks for responding, I insert it in a form:
~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~
Private Sub Confirm_Button_Click()
Dim a As String
On Error GoTo Err_Confirm_Button_Click
' 1 ANNUAL LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
If (Forms!login_form!LeaveType_ComboBox.Value = "AnnualLeave") Then
submitannualleave
' 2 MEDICAL LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "MedicalLeave") Then
submitmedicalleave
' 3 TIME OFF * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "Time-Off") Then
submittimeoff
' 4 CHILD CARE LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "ChildCareLeave") Then
submitchildcareleave
' 5 MATERNITY LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "MaternityLeave") Then
submitmaternityleave
' 6 PATERNITY LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "PaternityLeave") Then
submitpaternityleave
' 7 MARRIAGE LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "MarriageLeave") Then
submitmarriageleave
' 8 UNPAID LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "NoPayLeave") Then
submitunpaidleave
' 9 EXAM LEAVE * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "ExamLeave") Then
submitexamleave
' 10 Reservists * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "Reservists") Then
submitreservists
' 11 Compassionate Leave * * * * * * * * * * * * * * * * * * * * * * * * *
* * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "CompassionateLeave")
Then
submitcompassionateleave
' 12 Hospitalisation Leave * * * * * * * * * * * * * * * * * * * * * * * *
* * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "HospitalisationLeave")
Then
submitHospitalisationleave
' 13 Others * * * * * * * * * * * * * * * * * * * * * * * * * * * *
ElseIf (Forms!login_form!LeaveType_ComboBox.Value = "Others") Then
submitothers
End If
Exit_Confirm_Button_Click:
Exit Sub
Err_Confirm_Button_Click:
MsgBox Err.Description
Resume Exit_Confirm_Button_Click
End Sub 'End of Confirm_Button_Click//
Regards & God Bless, Edison