设计一个只接受字母键的文本框,在文本框text1中输入一串字符时,文本框text2中就即
展开全部
Private Sub Text1_KeyPress(KeyAscii As Integer)
If Not (Asc("a ") <= KeyAscii And KeyAscii <= Asc("z ") Or _
Asc("A ") <= KeyAscii And KeyAscii <= Asc("Z ")) Then
KeyAscii = 0
End If
Text2.Text = StrReverse(Text1.Text)
End Sub
If Not (Asc("a ") <= KeyAscii And KeyAscii <= Asc("z ") Or _
Asc("A ") <= KeyAscii And KeyAscii <= Asc("Z ")) Then
KeyAscii = 0
End If
Text2.Text = StrReverse(Text1.Text)
End Sub
追问
反序输出会少一个字母
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询