As both of you guys said, I did the loop with Chr(10)
If you insert this in my previous uploaded sample, it will return every line in all cells one by one as I wanted.Code:srcRow = 1 dstRow = 1 NumRows = Range("A2", Range("A2").End(xlDown)).Rows.Count For x2 = 1 To NumRows srcRow = srcRow + 1 dstRow = dstRow + 1 strLen = Len(Cells(srcRow, "B")) If strLen <> 0 Then test = Replace(Cells(srcRow, "B"), Chr(10), "", 1, -1, vbTextCompare) x = Len(test) anzLeer = strLen - x rightLine = Cells(srcRow, "B").Value For o = 0 To anzLeer newLineLen = InStr(rightLine, Chr(10)) leftLine = Left(rightLine, newLineLen) '#########SPLIT######### rightLine = Replace(rightLine, leftLine, "") If o = anzLeer Then leftLine = rightLine End If MsgBox (leftLine) Next End If Next End Sub
Now I only need to implement the rest of the code to split these lines i get returned.
But thats the lesser Problem thank you guys for helping![]()




Reply With Quote
