Is it possible to change the extent of a range entered as an argument in a function dependant on the contents of another cell?
For example, can a SUM function be written so that it evaluates SUM(A1:A3) if the content of a cell, say B1, is 3, or SUM(A1:A6) if B1 contains 6?
Apologies if this is a silly question and the answer is obvious!