Hi Guys -

So I'm nearly there, but there's one bit which is annoying me.

My original forumula which ranks a fixed colum is:

=RANK(K2, K$2:K$191)+COUNTIF(K$2:K2,K2)-1
Which works fine. WHat I need to do next is match the column to a date (selected_date).

So far I have this:

=RANK(INDEX($B2:$Z2,MATCH(selected_date,$B$1:$K$1,0)), K$2:K$191)+COUNTIF(K$2:K2,K2)-1
Obviously this doesn't work because of the bold bits. What I need to do is apply the first bit to the whole column, e.g. K$2:K$191 needs to be rows 2 - 191 of whichever column I've selected, and the same for the COUNTIF bit.

Aaaargh!

Can anyone help?

Thanks,
John