Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default Checkbox - Change color of label when clicked

Is there a way to change the background color of a checkbox label when it is
checked and change it back to white if it is un-checked?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 120
Default Checkbox - Change color of label when clicked

Hi

Private Sub CheckBox1_Change()
If CheckBox1.Value = True Then
CheckBox1.BackColor = RGB(0, 255, 0)
Else
CheckBox1.BackColor = RGB(255, 255, 255)
End If

End Sub

hth

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default Checkbox - Change color of label when clicked

Thanks Keith! Works great.

"Keith74" wrote:

Hi

Private Sub CheckBox1_Change()
If CheckBox1.Value = True Then
CheckBox1.BackColor = RGB(0, 255, 0)
Else
CheckBox1.BackColor = RGB(255, 255, 255)
End If

End Sub

hth


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Checkbox to change background color, font color and remove/ add bo Sara Excel Discussion (Misc queries) 2 May 1st 23 11:43 AM
CheckBox to change cell color John[_13_] New Users to Excel 6 January 18th 08 03:42 PM
Change Macro button color after clicked Cong Nguyen Excel Discussion (Misc queries) 2 November 30th 07 02:55 PM
Change label border color at runtime timspier[_3_] Excel Programming 3 March 11th 06 06:53 AM
how do I make checkbox color change when the value changes? Lynda Excel Discussion (Misc queries) 2 January 27th 06 12:12 PM


All times are GMT +1. The time now is 07:18 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"