Dan Waters
dwaters at usinternet.com
Wed Aug 6 14:56:02 CDT 2008
Ummm. I haven't had good luck using conditional formatting in unbound controls. Seems to work sometimes and not others - don't know why. How about just changing the backcolor of the control based the value of the checkbox? If chkInactivate = true then cboList.BackColor = 'Yellow' else cboList.BackColor = 'White' endif Put this code into any appropriate events - and you'll need to figure out what numbers correspond to the colors you want. Dan -----Original Message----- Open you form in design mode and go to the Format menu. There you will find the magical world of 'Conditional Formatting' where what you want can be achieved with no code. Lambert -----Original Message----- I have the following behind an unbound box in a form (Yeah, I know. Don't Start!). I also have a checkbox field called Inactivated on the form. How could this be rewritten to have a record turn color (for example, light yellow) when Inactivated is checked? Can I even do that in an unbound box? SELECT tStaff.StaffID, [LastName] & IIf(IsNull([FirstName]),"",", " & [FirstName]) & " -- " & [LanierID] AS Staff FROM tStaff ORDER BY [LastName] & IIf(IsNull([FirstName]),"",", " & [FirstName]); TIA -- Karen Rosenstiel Seattle WA USA