Maybe this...
=INDEX(IF(Y2=1,$AA$8:$AA$12,$AB$8:$AB$12),MATCH(Y8,$Y$8:$Y$12,0))
Maybe this...
=INDEX(IF(Y2=1,$AA$8:$AA$12,$AB$8:$AB$12),MATCH(Y8,$Y$8:$Y$12,0))
Biff
Microsoft MVP Excel
Keep It Simple Stupid
Let's Go Pens. We Want The Cup.
That works fine for y2=1. I added a coma and duplicated what you have for y2=2, but all I got were excel error messages. (I tried different combinations of "if"'s and "index"'s, to no avail.
If there are only 2 options for Y2, Y2 = 1 or Y2 = 2, then don't make any changes to the formula.
Another way to write it would be:
=INDEX(CHOOSE(Y2,$AA$8:$AA$12,$AB$8:$AB$12),MATCH(Y8,$Y$8:$Y$12,0))
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks