Results 1 to 5 of 5

Thread: Split Data in one cell into below rows

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #5
    VBAX Regular
    Joined
    Aug 2012
    Posts
    8
    Location
    Quote Originally Posted by snb
    Sub snb()
        sn = Cells(1).CurrentRegion
        For j = 2 To UBound(sn)
            c01 = c01 & Replace(sn(j, 1) & vbLf, vbLf, "_" & sn(j, 2) & vbLf)
        Next
        sn = Split(c01, vbLf)
        Cells(2, 5).Resize(UBound(sn) + 1) = Application.Transpose(sn)
    End Sub
    NB. Avoid merged cells in combination with VBA.
    Thank you very much for you help .
    Last edited by Aussiebear; 10-13-2024 at 04:38 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •