📄 v6j04-05.frm
字号:
VERSION 5.00
Begin VB.Form Form1
Caption = "Form1"
ClientHeight = 3195
ClientLeft = 60
ClientTop = 345
ClientWidth = 4680
LinkTopic = "Form1"
ScaleHeight = 3195
ScaleWidth = 4680
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command2
Caption = "Case"
Height = 495
Left = 2910
TabIndex = 2
Top = 2640
Width = 1455
End
Begin VB.TextBox Text1
Height = 555
Left = 2910
TabIndex = 1
Text = "Text1"
Top = 1260
Width = 1245
End
Begin VB.CommandButton Command1
Caption = "If Then"
Height = 495
Left = 1110
TabIndex = 0
Top = 2640
Width = 1455
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
strC = Text1
If UCase(strC) >= " A" And UCase(strC) <= "Z" Then '大小写字母均考虑
Print strC + "是字母字符"
ElseIf strC >= " 0" And strC <= " 9" Then ' 表示是数字字符
Print strC + "是数字字符"
Else ' 除上述字符以外的字符
Print strC + "其他字符"
End If
End Sub
Private Sub Command2_Click()
strC = Text1
If UCase(strC) >= " A" And UCase(strC) <= "Z" Then '大小写字母均考虑
Print strC + "是字母字符"
ElseIf strC >= " 0" And strC <= " 9" Then ' 表示是数字字符
Print strC + "是数字字符"
Else ' 除上述字符以外的字符
Print strC + "其他字符"
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -