In Excel 2010, using VBA, how can I breakapart a string when it finds a certain character?
Let say A1 = \"This is a | test of | the | emergency br
A1
\"This is a | test of | the | emergency br
Use Split()
Split()
Sub Sample() Dim Ret Dim strColumnA As String Dim i As Long strColumnA = "This is a | test of | the | emergency broadcast signal" Ret = Split(strColumnA, "|") For i = LBound(Ret) To UBound(Ret) Debug.Print Ret(i) Next i End Sub