megatronixs
Registered User.
- Local time
- Today, 01:50
- Joined
- Aug 17, 2012
- Messages
- 719
Hi all,
I have some code to check a combo box if a date field is filled in, then the combo box can't be empty.
I can make the error message appear, but the combo box does not want to change color and it does not recognize any other than value :-(
This is the code that I have, and it does not work like I wish it could.
(I took the database over from some one else and need to make improvements on it. the field names where not created by me).
I have some code to check a combo box if a date field is filled in, then the combo box can't be empty.
I can make the error message appear, but the combo box does not want to change color and it does not recognize any other than value :-(
This is the code that I have, and it does not work like I wish it could.
(I took the database over from some one else and need to make improvements on it. the field names where not created by me).
Code:
Private Sub cmbCurrentStatus_AfterUpdate() '<<<<<<<<<<<<<<<< Working on >>>>>>>>>>>>>
If IsNull(Me.[STEP 1 4 check current status]) And Not IsNull(Me.[Checked__date_]) Then
MsgBox "Checked (date) can't be empty if Current Status is filled in!", , "Incomplete Form!"
Me.[STEP 1 4 check current status].Value = RGB(255, 0, 0)
Else
Me.[STEP 1 4 check current status].BackColor = RGB(255, 255, 255)
End If
End Sub