For the part where the user presses "enter", it's easy enough.
A simple Debug.Print TextBox1.Text should print it as is.
If you want ot do the pseudo code, you could go with
tbText = Split(TextBox1.Text, vbNewLine)
For Each Line In tbText
Debug.Print Line
Next
Both of these however fail to detect the wordwrap.
I got a slightly hacky approach from this question
I used the hidden textbox, to keep the code simpler.
So I created another textbox, named measure, set AutoSize = True, WordWrap = False, Visible = False
and set then font options to the same as the first textbox. And used the following code:
Dim i As Long, w As Double, num As Long, memory As String
w = TextBox1.Width
tbText = Split(TextBox1.Text, vbNewLine)
For Each Line In tbText
measure.Text = Line
If measure.Width > w Then
shorten:
memory = measure.Text
While measure.Width > w
num = InStrRev(measure.Text, " ")
measure.Text = Left(measure.Text, num - 1)
i = Len(memory) - num
Wend
Debug.Print measure.Text
measure.Text = Right(Line, i)
If measure.Width > w Then
GoTo shorten
Else
Debug.Print measure.Text
End If
Else
Debug.Print Line
End If
Next
But feel free to use any of the other methods to get the width of the text for this code, or use an approach from the Link that Tim commented.