mercredi 24 août 2016

If statement that changes value of another cell than where the function is contained

I have a range of cells that either have a "Y" or "N" in them. I als0enter image description here have a "Score" cell that starts with a value of 4. I want to search those cells and if they contain a single "N" then I want the value in cell $S$17 (Score Cell) to be subtracted by 1. If they are all "Y" then I want the number value in $S$17 to remain the same. The formula itself is in cell $S$17 so when I have this formula =IF(COUNTIF(S2:S6,"N"),SUM(S17,-1),S17) it is giving me a circular Reference error. Is there a way to post this formula in a different cell but have the output posted in cell $S$17? I was thinking something like =IF(COUNTIF(S2:S6,"N"),S17 = SUM(S17,-1),S17). I know this isn't correct syntax but thats the idea. Or if thats not possible just avoid the circular reference.

Aucun commentaire:

Enregistrer un commentaire