Hi all,
Below is the functions I used in a lucky draw thing and it works but I don't really get how the middle part works
Can somebody please explain the aggregation part of it? and how does the range works in the function Match also.
=IF(ROWS(C$2:C2)>B$2,"",INDEX(A$2:A$6,AGGREGATE(15,6,((ROW(A$2:A$6)-ROW(A$2)+1)/ISNA(MATCH(A$2:A$6,C$1:C1,0))),RANDBETWEEN(1,ROWS(A$2:A$6)-COUNTA(C$1:C1)+1))))
Just need 3 columns for this function.
Column A is the draw list.
Column B has only one cell which is the number of draws
Column C is where to place the above function and can simply drag down to the number you need and can be refresh by pressing F9.
When I try to figure out how it works, I found out that some of the middle parts will get errors if they just stand alone.
Thank you in advance for your time and effort!
Regards,
Leo
Bookmarks