我的sheet1看起来如下:
A B C D1 7 8 92 x3 y4 z
在Sheet2中,我想加入这样的外观:
A1 x |72 y |83 z |9
我尝试过:
=CONCATENATE(Sheet1!A2," | ",Sheet1!B$1)
但这给了我:
A1 x |72 y |73 z |7
尝试,
=CONCAT(Sheet1!A2,"|", INDEX(Sheet1!B$1:D$1, , ROW(1:1)))
另一个选项
=CONCATENATE(Sheet1!A2," | ",OFFSET(Sheet1!$A$1,0,ROW()))
或
=CONCATENATE(Sheet1!A2," | ",INDIRECT("Sheet1!" & ADDRESS(1,ROW()+1)))
注意: OFFSET
和INDIRECT
都是挥发性功能。有关挥发性功能的详细信息,请参阅此。