1
votes

I am trying to create a rule for conditional formatting that highlights the column yellow if the header of the table contains the same value as is contained in cell A1, but it says my formula has an error. Does anyone have any ideas?

Here is my formula:

 =CELL("col", INDIRECT(ADDRESS(ROW(), COLUMN()))) = (MATCH($A$1,Table1[#Headers],0)+2)

EDIT: The formula works when I put it into a cell, just not when I put it into the 'new rule' section of conditional formatting.

1

1 Answers

1
votes

Create a conditional rule applying to the relevant column (say G with header in $G$1) with the following rule:

=AND(G1<>"",$A$1=$G$1)

I don't think you can reference the header with the Table Structured reference that you used which is why I hardcoded the range. Regards,