I'm making a random team selector but I'm getting a #NUM!
error saying that "Parameter 2 Value 20" or "Parameter 2 Value 25" is out of range. From what I understand, they are not.
The parameters referred by the function are in other sheets.. Here is the link to it. Example:
Do you think this is a bug or am I doing something wrong?
Best Answer
I see commands like
The second parameter of
index
is not the absolute row number but is relative to the range specified as the first argument. For example,=index(A$2:A$19, 1)
refers to A2=index(A$2:A$19, 18)
refers to A19=index(A$2:A$19, 19)
throws an errorTo fix this, either change the range of
randbetween
:or, if you want to refer by absolute row numbers, use
indirect
: