Private Sub Text1_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyF5 Then
Text1.SelStart = Len(Text1)
Text1.SelText = Now
End If
End Sub
Private Sub Text1_KeyDown(KeyCode As Integer, Shift As Integer)
Dim s As String
Dim i As Long
If KeyCode = vbKeyF5 Then
s = Left(Text1.Text, Text1.SelStart)
s = s & Date
i = Len(s)
s = s & Right(Text1.Text, Len(Text1.Text) - Text1.SelStart)
Text1.Text = s
Text1.SelStart = i
End If
End Sub