A.Private Sub Text1_KeyPress(KeyAscii As Integer) If KeyAscii<65 Or KeyAscii>90 Then MsgBox"请输入大写字母" KeyAscii=0 End If End Sub B.Private Sub Text1_KeyDown(Keycode As Integer, Shift As Integer) If KeyCode<65 Or Keycode>90 Then MsgBox"请输入大写字母" KcyCode=0 End If End Sub C.Private Sub Text1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single) If Asc(Text1. Text)<65 Or Asc(Text1. Text)>90 Then MsgBox"请输入大写字母" End If End Sub D.Private Sub Text1_Change() If Asc(Text1. Text)>64 Or Asc(Text1. Text)<91 Then MsgBox"请输入大写字母" End If End Sub