Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Cli
ck
TextBox1.Text = TextBox1.Text & DateTime.Now & " " & DateTime.Now.Millisecond & Chr(13) & Chr(10)
End Sub
End Class
其中DateTime.Now.Millisecond 即為毫秒級的時間
Chr(13) 、 Chr(10)分別表示換行符和回車鍵 最簡單的方法就是:
dim t as string
t=DateTime.Now.Millisecond