title: How to split string into cells for multiple cells?
body: <p>I want my code to go through a list of cells containing names and split them up into the cells next to the original. I have some basic code to do the first bit, but I'm struggling to get it to cycle through the rest of my list, and also outputting it next to the original rather than in A1 as it does currently. I presume it's an issue with the 'Cell' part of the code but I can't quite fix it.</p>
  
  <pre><code>Sub NameSplit()
  
      Dim txt As String
      Dim i As Integer
      Dim FullName As Variant
      Dim x As String, cell As Range
  
      txt = ActiveCell.Value
  
      FullName = Split(txt, " ")
  
      For i = 0 To UBound(FullName)
  
          Cells(1, i + 1).Value = FullName(i)
  
      Next i
  
  
  End Sub
  </code></pre>