Here's the basic idea of what the old .Print()
command did.
*It was really more complex than this, but I'm not that motivated this morning.
Public Class Form1
Private lines As New List(Of String)
Private Async Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Button1.Enabled = False
For a As Integer = 10 To 50 Step 2
Print(a)
Await Task.Delay(500)
Next
Button1.Enabled = True
End Sub
Private Sub Print(ByVal output As String)
lines.Add(output)
PictureBox1.Invalidate()
End Sub
Private Sub PictureBox1_Paint(sender As Object, e As PaintEventArgs) Handles PictureBox1.Paint
Dim rowHeight = PictureBox1.Font.Size + 5
For y As Integer = 0 To (lines.Count - 1)
e.Graphics.DrawString(lines(y), Me.Font, Brushes.Black, New Point(10, (y * rowHeight) + 10))
Next
End Sub
End Class
Code in action:
