关于Private Sub Form_Load()
Open “d:\data.txt” For Output As #3
Text1.Text = “”
End Sub
Private Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
If Text1.Text = “end” Then
Close #3
Else
Write #3, Text1.Text
Text1.Text = “”
End If
End If
End Sub的问题
KeyAscii = 13 指按下ENTER键。