I have conditionally formatted a cell to turn a different color based on whether the value in it is below, between, or above two numbers in columns AU and AV. What I would like to do is have a cell to the left of this hold a value also based on what is in AU and AV. For instance, if the value in the colored cell is bigger than AV, then I want the cell to the left to hold a value of 25. If it is between AV8 and Au8, then cell to the left = 15, and otherwise cell to left = 0. The problem with my formula is that I want to be able to have this work for multiple cells to the left of multiple values pulling from multiple values in AU and AV. I am thinking formulaR1C1 might work here but I don't know how to use it. Also, I am really writing this in VBA but for purposes of this question it might be easier to just understand the formula in excel first.
Range(Cells(i, j * 4 + 2), Cells(i + 1, j * 4 + 4)).FormulaR1C1 =
"=IF(J8 >=$AV8,25,IF(J8 >=$AU8,15,0))"
Aucun commentaire:
Enregistrer un commentaire