Hi,
I am trying to find a way to count the number of cells that are conditionally formatted with a certain fill colour.
I have searched the web and found several posts that say how tricky it can be and and some that suggest using a function that recreates the formula of the conditional formatting. but sadly, I do not know how to replicate easily the formula used, and the code i found to count the Conditional formats does not appear to work. I believe it is because of the type of conditional format I have selected.
So can any one help? here is what I am trying to do.
I have a quite large and complex spreadsheet that has lots of data, amongst this are 4 columns containing user ID's (A user can have a Main identifier and up to 3 alternate Identifiers). But I need to check for Duplicate user ID's across all 4 ID columns eg Does and ID exist in Col H, or Col K or Col M or Col T? if so colour all the duplicate cells in red.
Now Excel 2007's conditional formatting has let me do this very easily, because it has a built in function that allows me to format "only Unique or Duplicate Values" and it applies to the "Range selected". So I can select the non contiguous columns of H, K, M and T and select a fill colour of Red, and this works perfectly.
However, I need to count those coloured cells. As I said right at the beginning, I do not know how i could construct the formula to be the same as the conditional formatting.
The code I have found on other sites does not work on the cells Conditionally formatted in this way (its does work with cells that are conditionally formatted in a far simpler way, so I am sure it is not me using the code wrong)
Any help would be greatly appreciated
Bookmarks