Formula to Find First Cell in a Row with Values

C

cardan

Hello, I am trying to find the value in a series of cash flows that is
the first month to have a cash flow. I have the formula to find the
max, which is =SUMPRODUCT((MAX(($a2:$z2>0)*($a$1:$z$1)))), (thank you
Rick Rothstein!)where row 2 equals the cash flow and row 1 equals the
corresponding date.

I am now looking to find the first month with a number that is not
zero. I tried switching the MAX to MIN and the switching the sign
around. All I get is 0 when I do that. Any suggestions? Thanks again.

Dan
 
R

Rick Rothstein

Try this array-entered** formula...

=(MIN(IF(($A2:$Z2>0),$A$1:$Z$1),99999))

**Commit this formula with Ctrl+Shift+Enter, not just Enter by itself.
 

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