Form filled unfilled control and show it by color to user
Private Sub CmdSubmitCheckIn_Click()
On Error GoTo form1_Err
'******************************************************
'******************************************************
'*********** *********
'*********** -1-Data verification *********
'*********** *********
'******************************************************
'******************************************************
'
'Checking the quality of the document, is it worth to enter in DCC
'Some documents like invoices, receipts are not worth to enter in DCC
'Quality of the doc is primary for filtering the document
'Here the user has to enter the document qualifications
'the program will evaluate the entry and will guide the user
'If the quality control is ok, then the document will be prepared for the
transfer
'............................................................................
'///////////// -11-reset form colors /////////////
'............................................................................
Dim MyColor As Long
MyColor = RGB(190, 190, 190)
Me!txtSessionID.BackColor = RGB(255, 255, 255) '--------doc id
Me!LbtMajotminorEffect1.BackColor = MyColor '--1
Me!LbtMajotminorEffect2.BackColor = MyColor '--1
Me!lblEffectlongevity.BackColor = MyColor '--2
Me!lblAmelioratecomp1.BackColor = MyColor '--3
Me!lblAmelioratecomp2.BackColor = MyColor '--3
Me!lblActualjob1.BackColor = MyColor '--4
Me!lblActualjob2.BackColor = MyColor '--4
Me!lblprojmgrsignature.BackColor = MyColor '--5
Me!lblClientsignature.BackColor = MyColor '--6
Me!lblApprovedStamp.BackColor = MyColor '--7
'............................................................................
'///////////// -12-"Check in" form`s data entry error handling /////////////
'///////////// check all the text box if any of them are left blank
/////////////
'............................................................................
'-121-------------------Doc ID--------------------
If IsNull(txtSessionID) Then
a = MsgBox("ID Box is left empty", vbOKOnly, "Revise your entrys")
Me!txtSessionID.BackColor = vbYellow
End If
'-122-------------------1--------------------
If IsNull(FrameMajotminorEffect) Then
a = MsgBox("Box No: 1 is left empty", vbOKOnly, "Revise your entrys")
Me!LbtMajotminorEffect1.BackColor = vbYellow
Me!LbtMajotminorEffect2.BackColor = vbYellow
End If
'-123-------------------2--------------------
If IsNull(frameEffectlongevity) Then
a = MsgBox("Box No: 2 is left empty", vbOKOnly, "Revise your entrys")
Me!lblEffectlongevity.BackColor = vbYellow
End If
'-124-------------------3--------------------
If IsNull(FrameAmelioratecomp) Then
a = MsgBox("Box No: 3 is left empty", vbOKOnly, "Revise your entrys")
Me!lblAmelioratecomp1.BackColor = vbYellow
Me!lblAmelioratecomp2.BackColor = vbYellow
End If
'-125-------------------4--------------------
If IsNull(FrameActualjob) Then
a = MsgBox("Box No: 4 is left empty", vbOKOnly, "Revise your entrys")
Me!lblActualjob1.BackColor = vbYellow
Me!lblActualjob2.BackColor = vbYellow
End If
'-126-------------------5--------------------
If IsNull(FramePojMgrSign) Then
a = MsgBox("Box No: 5 is left empty", vbOKOnly, "Revise your entrys")
Me!lblprojmgrsignature.BackColor = vbYellow
End If
'-127-------------------6--------------------
If IsNull(frameClientsignature) Then
a = MsgBox("Box No: 6 is left empty", vbOKOnly, "Revise your entrys")
Me!lblClientsignature.BackColor = vbYellow
End If
'-128-------------------7--------------------
If IsNull(FrameApprovedstamp) Then
a = MsgBox("Box No: 7 is left empty", vbOKOnly, "Revise your entrys")
Me!lblApprovedStamp.BackColor = vbYellow
End If
'all data is ok doc transfer can start