Need help with IF statement (function)

M

managingcrap

I have 1,2,3,4,5,0 for cell A1, B1, C1, D1, E1, and F1 respectively.
want a function that would give me result of for example D2 with 25% an
E2 with 50%. This means that when the next number is zero, the functio
would provide a result for the last two cells with numbers (other tha
zero) prior to that zero. Please see attached picture

+-------------------------------------------------------------------
|Filename: excel help.jpg
|Download: http://www.excelbanter.com/attachment.php?attachmentid=927
+-------------------------------------------------------------------
 
C

Claus Busch

Hi,

Am Fri, 8 Nov 2013 13:13:19 +0000 schrieb managingcrap:
I have 1,2,3,4,5,0 for cell A1, B1, C1, D1, E1, and F1 respectively. I
want a function that would give me result of for example D2 with 25% and
E2 with 50%. This means that when the next number is zero, the function
would provide a result for the last two cells with numbers (other than
zero) prior to that zero. Please see attached picture.

in A2 try:
=IF(A1=0,"",IF(MATCH(0,B1:$F$1,0)=1,0.5,IF(MATCH(0,B1:$F$1,0)=2,0.25,"")))
und drag the formula to E2


Regards
Claus B.
 

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