Excellence
Member
Good day. I need help regarding the Countif function. The problem is: the range parameter is variable. I will try to put an example in order to make it easier to understand.
On column A we have 10 rows from 1 to 10. In A1 we have the value 2, so as in the cell A4 and A10. In cell A2 we have the value 3, in A5 the value 4.
What I want is: calculate how many times the value 2 appeared in the range that contains 4 values, starting from row 1 (here is the range A1:A5). I also want to have the possibility to change the number of values contained, like instead of 4 to have 5values. My first thought was to create another column that would count the values in column A row by row and use a match function in combination whit address but it did not work. The problem is even more difficult since this range is on a different sheet. Any ideas?
On column A we have 10 rows from 1 to 10. In A1 we have the value 2, so as in the cell A4 and A10. In cell A2 we have the value 3, in A5 the value 4.
What I want is: calculate how many times the value 2 appeared in the range that contains 4 values, starting from row 1 (here is the range A1:A5). I also want to have the possibility to change the number of values contained, like instead of 4 to have 5values. My first thought was to create another column that would count the values in column A row by row and use a match function in combination whit address but it did not work. The problem is even more difficult since this range is on a different sheet. Any ideas?