I want to return a value from a previous cell if the cell to the left of it (on the same row) is X.
For all rows with 115 in A column, I want to put the formula in column C, to get the value from the 1st previous cell in column B for which column A shows 20.
31 Answer
Here it is, for exmple for C1:
=IF(A1=115,LOOKUP(2,1/($A$1:INDIRECT(ADDRESS(ROW(A1)-1,2))=20),B:B),"")