Multiple returned values into a single cell
There's probably a more elegant solution out there, but it should work:
=SUBSTITUTE(IF(B2="yes",B1&", ","")&IF(C2="yes",C1&",
","")&IF(D2="yes",D1&", ","")&IF(E2="yes",E1&", ",""),",
","",COUNTIF(B2:E2,"yes"))
You can add more IF statements inside the SUBSTITUTE function if you have
more columns than your example suggests.
HTH,
Elkar
"Jeff" wrote:
Hi,
I have an Excel spreadsheet, where I am trying to put multiple results, into
a single cell. For example, I have a dropdown selector "Yes" or "No" in a
row that states whether I want a column Market name returned:
a b c d
e
1 Atlanta Chicago Cincinnati
Cleveland
2 Yes Yes No
Yes
3
What I would like to do is this: return results, within a single cell (say,
a1), all markets that say "Yes", like this: "Atlanta,Chicago,Cleveland". I
would want them speparated by a comma...
Thanks for any help, it's driving me crazy. I've tried H and V lookups,
and I can bring back one market name, but getting the multiple names into
one cell is baffling.
Jeff
|