Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data control labels

Status
Not open for further replies.

proguru

Programmer
Mar 31, 2001
19
0
0
PY
Hi
I have a form with many check boxes with their labels. I want to change the color of the labels when the controls are checked. How can i do this?
Is there a way to access the label of a particular check box through code?

Thanks in advance
 
Try the code below on the After Update event on the check box
If tick = -1 Then
Label2.BackColor = 16777164
Else
Label2.BackColor = 13434828
End If

Dont forget to change
tick = your Check box name
label2 = your label name

Hope this helps
Hymn
 
thanks for the awswer but the after update does not work with check boxes
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top