Thanks Ratcat, the luck will be needed, that's for sure!
Robert,
First up, 2 sets of brackets can be removed (ie"(if" is not needed nor are the corresponding closing bracket) this changes it from
=IF($B13="X","",IF($R13>0,IF(AND($R13<=Y$8,$R13>X$8),$S13,IF($P13>0,IF(AND($P13<=Y$8,$P13>X$8),$Q13,IF($N13>0,IF(AND($N13<=Y$8,$N13>X$8),$O13,IF($L13>0,IF(AND($L13<=Y$8,$L13>X$8),$M13,IF($I13>0,(IF(AND($I13<=Y$8,$I13>X$8),$E13,(IF(AND($H13<=Y$8,$H13>X$8),$E13,""))))))))))))))
to
=IF($B13="X","",IF($R13>0,IF(AND($R13<=Y$8,$R13>X$8),$S13,IF($P13>0,IF(AND($P13<=Y$8,$P13>X$8),$Q13,IF($N13>0,IF(AND($N13<=Y$8,$N13>X$8),$O13,IF($L13>0,IF(AND($L13<=Y$8,$L13>X$8),$M13,IF($I13>0,IF(AND($I13<=Y$8,$I13>X$8),$E13,IF(AND($H13<=Y$8,$H13>X$8),$E13,""))))))))))))
Other than that, almost everything looks consistent (eg in terms of referencing technique) except...
for the last section which tests to see if I13 is greater than zero + performs an And test & then breaks the "convention" of grabbing the next column as a result because it references $E13 (conventon suggests the resulting cell should be in column J (ie offset by one column)).
past my bed-time, good luck!
Rob
Bookmarks