Excel:按行列数 [英] Excel : Columns by row value
本文介绍了Excel:按行列数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否有一种不使用宏或脚本的方法来获得此结果?
Is there a method without using macro or script, to get this result?
Bus Line L1 L2 L3 L4 Result
Stops
1 X X L2,L4
2 X L4
3 X X L1,L3
我需要为行中的每个"X"串联"COLUMN'S NAME".
I need to concatenate COLUMN'S NAME for each "X" on rows.
推荐答案
在 F2 中,输入数组公式:
=TEXTJOIN(",",TRUE,IF(B2:E2="X",$B$1:$E$1,""))
并复制下来:
数组公式必须使用 Ctrl + Shift + Enter 输入,而不仅仅是 Enter 键.如果正确完成此操作,则公式将显示在公式栏中,并带有大括号.
Array formulas must be entered with Ctrl + Shift + Enter rather than just the Enter key. If this is done correctly, the formula will appear with curly braces around it in the Formula Bar.
这篇关于Excel:按行列数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文