Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

The SUM function in excel works in both this form:

=SUM(1,2,3,4,5)

and this form:

=SUM({1,2,3,4,5})

However, the CONCATENATE function does not. I have a range A1:A5 containing {1,2,3,4,5}, which works fine in SUM(A1:A5), giving 15. However, CONCATENATE(A1:A5) gives 1, not 12345.

Is there some way to "unpack" this range into multiple arguments, such that CONCATENATE(UNPACK({1,2,3,4,5})) is equivalent to CONCATENATE(1,2,3,4,5)?

Expressed in various ways in some programming languages:

concatenate.apply(null, [1, 2, 3, 4, 5])  // javascript
concatenate(*[1, 2, 3, 4, 5])  # python
concatenate(unpack([1, 2, 3, 4, 5])) -- lua
share|improve this question

1 Answer 1

There's no worksheet function in Excel that allows you to concatenate a range or array. You would probably need VBA - try googling "Aconcat"

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.