sbSplit

Former function name was WSSplit

Excel lacks a worksheet function split which can split a cell content onto several cells with a given delimiter.

The user defined function sbSplit below solves this.

sbSplit implements the VBA split function as described here:

Microsoft Docs Office VBA Reference - Split function

Please read my Disclaimer.

Function sbSplit(sExpression As String, _
    Optional sDelimiter As String = " ", _
    Optional iLimit As Integer = -1, _
    Optional iCompare As Integer) As Variant
'Source: https://berndplumhoff.gitbook.io/sulprobil/excel/excel-vba-solutions/sbsplit
'V0.2 21-Oct-2020
'Implements the VBA split function as described here:
'https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/split-function
sbSplit = Split(sExpression, sDelimiter, iLimit, iCompare)
End Function

Last updated