ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Checkbox (https://www.excelbanter.com/excel-discussion-misc-queries/202874-checkbox.html)

AlliSun

Checkbox
 
Is is possible to set up a formula that if a checkbox is checked it will
highlight a particular field?

And how do you bold a checkbox/mark?

Brad Vogt

Checkbox
 
The checkbox should have a link cell, then conditional formatting to check
that cell and highlight whichever field based on what is in the linked cell.
ie. TRUE or FALSE will be what is in the link cell.

Right click the checkbox and go to Format Control, then enter the cell link
that you want to use to reference in your conditional format.

"AlliSun" wrote:

Is is possible to set up a formula that if a checkbox is checked it will
highlight a particular field?

And how do you bold a checkbox/mark?


FSt1

Checkbox
 
hi
formulas return values, they can not perform actions like "highlight a
particular field". but if you are talking about a activeX contol on the
sheet, you can put code in the sheet to high light a cell or range of cells.
in design mode, right click the checkbox then click view code.
Private Sub CheckBox1_Click()
If CheckBox1.Value = True Then
Range("B5").Interior.ColorIndex = 41
Else
Range("B5").Interior.ColorIndex = xlNone
End If
End Sub

for a range of cells....
Range("B5:B15").Interior.ColorIndex = 41

see this site for color index numbers
http://www.mvps.org/dmcritchie/excel/colors.htm

regards
FSt1


"AlliSun" wrote:

Is is possible to set up a formula that if a checkbox is checked it will
highlight a particular field?

And how do you bold a checkbox/mark?



All times are GMT +1. The time now is 10:45 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com