题目内容
在窗体上画一个命令按钮command1和两个文本框,名称分别为Text1和Text2。编写如下两个事件过程:
Dim Str1 As String, str2 As String
Private Sub form_load()
Text1.Text=""
Text2.Text=""
Text1.Enabled=False
Text2.Enabled=False
End Sub
Private Sub Form.
str1=str1& Chr(KeyAscii)
End Sub
Private Sub Form.
str2=str2 & Chr(KeyCode)
End Sub
Private Sub Command1
Text1.Text=str1
Text2.Text=str2
str1=""
str2=""
End Sub
当在设计阶段的窗体的KeyPreview属性设置为True时,程序运行过程中,在键盘上输入小写字母abc,然后单击命令按钮,则文本框Text1中显示的内容为
查看答案
搜索结果不匹配?点我反馈
更多问题