Skip to content

Instantly share code, notes, and snippets.

@chhetripradeep
Created October 7, 2017 10:09
Show Gist options
  • Save chhetripradeep/db6821b8a80ef862e288ce71059fa190 to your computer and use it in GitHub Desktop.
Save chhetripradeep/db6821b8a80ef862e288ce71059fa190 to your computer and use it in GitHub Desktop.
Sub parser()
Dim N As Long, wf As WorksheetFunction
Set wf = Application.WorksheetFunction
N = Cells(Rows.Count, "A").End(xlUp).Row
Dim i As Long, j As Long, k As Long
For i = 1 To N
ary = Split(wf.Trim(Cells(i, "A").Text), " ")
k = 2
For j = LBound(ary) To UBound(ary)
Cells(i, k).Value = ary(j)
k = k + 1
Next j
Next i
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment