In Excel, I have a long, complex expression (Expression A) that I am using in a formula. I want this formula to return the value of Expression A except in the case where that expression is equal to some specific value (0 for example), in which case it returns something else, like "(none)".

Is there a way of writing `=IF(<Expression A> = 0, "(none)", <Expression A>)`

that wouldn't require me to repeat the entirety of Expression A twice? (Sort of like how `IFERROR`

works, except with a custom condition)

`IFERROR(INDEX(Table1,ROWS(C$2:C2),COLUMN(C2)), IFERROR(INDEX(Table2,ROWS(C$2:C2)-ROWS(Table1),COLUMN(C2)), ""))`

(This is the actual formula I'm using for Expression A.) – Ajedi32 Jan 17 '13 at 21:58`COLUMN(C2)-1`

. The advantage apart from a cleaner formula is that it halves calculation time, as the operation has to be carried out only once. And to avoid cluttering the visual, simply hide column with expression A. – Peter Albert Jan 17 '13 at 22:46