First non blank number in a row

G

Guest

I've been trying to figure out how i can identify the first non blank cell in
a series and show me which column that cell is in. e.g.
Col1 Col2 Col3 Col4 Col5
Row1 34.2 3.45 45.1 432.1
Row2 43.1 541
Row3 34.1 51.12

What formula can i key in Col6, that shows me the for row2,that col2 is the
first non blank number, and for row 3, col3 is the first non blank number and
similarly for Row1, col1 is the first non blank number.

Thanks
 
B

Bob Phillips

In F2

=MIN(IF(A2:E2<>"",COLUMN(A2:E2)))

which is an array formula, so commit with Ctrl-Shift-Enter

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
B

Bill Kuunders

You did mention that the result should be in colmn 6.
As long as you do not need to add more columns a nested if formula will do
it.

=IF(A1>0,1,IF(B1>0,2,IF(C1>0,3,IF(D1>0,4,IF(E1>0,5,"none")))))
 
G

Guest

Another way

=MATCH(TRUE,A2:D2<>"",0)


entered with ctrl + shift & enter


regards,

Peo Sjoblom
 
B

Bill Kuunders

excellent options

Thanks Bob and Peo

Bill K
Peo Sjoblom said:
Another way

=MATCH(TRUE,A2:D2<>"",0)


entered with ctrl + shift & enter


regards,

Peo Sjoblom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top