选中任一表单复选框时如何突出显示单元格(将多个复选框链接到一个单元格) [英] How to highlight a cell when either form checkbox is checked (linking multiple checkboxes to one cell)

查看:152
本文介绍了选中任一表单复选框时如何突出显示单元格(将多个复选框链接到一个单元格)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我是excel(和编码)的真正新手。 我已经弄清楚,使用条件格式,如果另一个单元格的值发生变化(基于复选框更改),则突出显示一个单元格。 我所拥有的是具有复选框的多个单元格(因为MAC用户需要能够运行它,所以不能将
成为ActiveX checbox),如果选中其中任何一个复选框,则必须突出显示另一个单元格。

Hi there, I'm a real newbie with excel (and coding).  I've figure out, using Conditional Formatting, to highlight one cell if the value of another cell changes (based on a checkbox changing).  What I have are multiple cells with checkboxes (cannot be ActiveX checboxes since MAC users need to be able to run it), if any one of those checkboxes are checked, another cell has to be highlighted.

例如,单元格A1,B1,C1,D1,E1都有复选框。 如果选中其中任何一个,则需要突出显示单元格F1。 我能够设置它,以便如果检查A1,则单元格G1表示"TRUE"。然后细胞F1突出显示。 
当我将所有复选框链接到单元格G1并仅选择B1时 - 检查所有单元格(A1,C1,D1,E1)并突出显示单元格F1。  

For example, Cells A1, B1, C1, D1, E1 all have check boxes.  If any one of those are checked, cell F1 needs to be highlighted.  I was able to set it up so that if A1 is checked, then cell G1 says "TRUE" then cell F1 highlights.  When I link all the checkboxes to cell G1 and select only B1 - all cells (A1, C1, D1, E1) are checked AND cell F1 is highlighted.  

如果选中(或全部)A1,B1,C1,D1和/或E1中的任何一个,我需要能够突出显示一个单元格。 

I need to be able to have one cell highlighted if any one of (or all) A1, B1, C1, D1, and/or E1 is checked. 

感谢任何/所有帮助!

(我使用VBA还是宏? 对于这类东西我很文盲! )

(Do I use VBA or Macros?  I am quite illiterate when it comes to this sort of stuff!)

推荐答案

我假设您的问题是单元格A1,B1,C1, D1,E1是将单元格链接到复选框,并在选中/取消选中复选框时更改值。如果没有,以下将不起作用。

I am assuming from your question that cells A1, B1, C1, D1, E1 are linked cells to the checkboxes and change value when the checkboxes are checked/unchecked. If not, following will not work.

我没有Mac,所以我不确定条件格式的用户界面是否相同所以我将提供一个指导PC可能需要调整,如果不完全相同。

I don't have a Mac so I am not sure if the user interface for the conditional formatting is the same so I'll provide guidelines for a PC and you might need to adjust if not exactly the same.


  1. 选择单元格F1
  2. 选择条件格式(在主页功能区上)
  3. 如果您已经将条件格式应用于单元格,则选择清除并删除任何先前的条件格式,然后重复上一步并第二次跳过此步骤。
  4. 选择新建规则
  5. 选择"使用公式确定要格式化的单元格"
  6. 在公式字段中输入以下公式。 (你应该可以从这里复制并粘贴到公式字段中)
  7. = OR(A1 = TRUE,B1 = TRUE,C1 = TRUE,D1 = TRUE,E1 = TRUE)
  8. 选择格式按钮并设置所需格式
  9. 单击确定再次单击确定完成


这篇关于选中任一表单复选框时如何突出显示单元格(将多个复选框链接到一个单元格)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆