You could write a Select Case statement to set the forecolor of the combobox, and then run the code from the After_Update or On-Change event. This would set the font to the chosen colour based on the word selected from the list.
I don't know of any way to change the colour of the elements in the combobox list before one is selected.
Thanks Lightning for the advice but I'm sure there is a way. What I'm trying to achieve is a notification for users to prioritise an event with colours for individual clients on our database so that it is immediately and visually apparent what their status is. Maybe there is another approach I could take. Any suggestions??
I use the following code for a combo box that displays the status of a yes/no field in either red or black. It can be expanded to cover a value list. Good luck.
Private Sub cmbDistroyed_AfterUpdate()
If Me!cmbDistroyed = 0 Then
Me!cmbDistroyed.ForeColor = 0
Else
Me!cmbDistroyed.ForeColor = 255
End If
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.