Concatenate Array
This is a small piece of code that can be used to concatenate the elements of an array.
You can use it on elements of a listbox or combobox. See the attached file for reference.
Function ConcatenateArrayElements(arrElement As Variant, Optional _ strConcatenator As String = ", ") As String ConcatenateArrayElements = Join(arrElement, strConcatenator) End Function
Attachment | Size |
---|---|
ConcatenateArray.xls | 24 KB |
»
- Vishesh's blog
- Login or register to post comments
- 11418 reads
How can I concatenate from
How can I concatenate from the range itself
MsgBox ConcatenateArrayElements(Sheet1.Range("A2:A6"), ", ")