Befuddled by Count blank cells Formula!

H

harteorama

Hi all,

Can anybody please help... i'm really struggling here!

I need to count the number of blank cells (in a row) that occurs
between 2 words S and C. I have the formula below and i cant get the
damn thing to work!


=SUMPRODUCT(--(G5:AX5="S"),--(G5:AX5="C"))


Any help GREATLY appreciated..

Cheers

P :)
 
P

Peo Sjoblom

Try

=COUNTBLANK(INDEX(G5:AX5,MATCH("S",G5:AX5,0)):INDEX(G5:AX5,MATCH("C",G5:AX5,0)))
 
H

harteorama

Peo,

You are a super star - worked liked a treat - many many many
thanks :)

Cheers

P
 
Top