📄 frmmain.frm
字号:
VERSION 5.00
Begin VB.Form frmMain
Caption = "信息测试"
ClientHeight = 6015
ClientLeft = 60
ClientTop = 345
ClientWidth = 6555
Icon = "frmMain.frx":0000
LinkTopic = "Form1"
ScaleHeight = 6015
ScaleWidth = 6555
StartUpPosition = 2 '屏幕中心
Begin VB.Frame Frame1
Height = 4335
Left = 4440
TabIndex = 1
Top = 0
Width = 2055
Begin VB.CommandButton cmdDBCharN
Caption = "验证数字存在"
Height = 375
Left = 360
TabIndex = 9
Top = 3480
Width = 1335
End
Begin VB.CommandButton cmdDBChar
Caption = "验证中文字符"
Height = 375
Left = 360
TabIndex = 7
Top = 2760
Width = 1335
End
Begin VB.TextBox txtExistC
Height = 375
Left = 360
TabIndex = 6
Top = 960
Width = 1335
End
Begin VB.CommandButton cmdExistC
Caption = "验证字符存在"
Height = 375
Left = 360
TabIndex = 5
Top = 1320
Width = 1335
End
Begin VB.CommandButton cmdExist
Caption = "验证密码存在"
Height = 375
Left = 360
TabIndex = 4
Top = 2040
Width = 1335
End
Begin VB.TextBox txtExist
Height = 375
Left = 360
TabIndex = 3
Top = 1680
Width = 1335
End
Begin VB.CommandButton cmdFunc
Caption = "测试"
Height = 375
Left = 360
TabIndex = 2
Top = 240
Width = 1335
End
Begin VB.TextBox txtDBChar
Height = 375
Left = 360
TabIndex = 8
Top = 2400
Width = 1335
End
Begin VB.TextBox txtDBCharN
Height = 375
Left = 360
TabIndex = 10
Top = 3120
Width = 1335
End
End
Begin VB.TextBox txtValue
Height = 6015
Left = 0
MultiLine = -1 'True
ScrollBars = 2 'Vertical
TabIndex = 0
Top = 0
Width = 4335
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub cmdDBChar_Click()
MsgBox Asc(txtDBChar.Text)
End Sub
Private Sub cmdDBCharN_Click()
MsgBox Chr(CLng(txtDBCharN.Text))
End Sub
Private Sub cmdExist_Click()
Dim i As Integer
Dim strValue As String
strValue = txtExist.Text
For i = 0 To 41
If CharCode(i, 1) = strValue Then
MsgBox "信息已经存在,冲突字符为:" & CharCode(i, 0), vbOKOnly + vbCritical, "信息验证"
Exit Sub
End If
Next
MsgBox "信息不存在,可以使用。", vbOKOnly + vbInformation, "信息验证"
End Sub
Private Sub cmdExistC_Click()
Dim i As Integer
Dim strValue As String
strValue = txtExistC.Text
For i = 0 To 41
If CharCode(i, 0) = strValue Then
MsgBox "信息已经存在。", vbOKOnly + vbCritical, "信息验证"
Exit Sub
End If
Next
MsgBox "信息不存在,可以使用。", vbOKOnly + vbInformation, "信息验证"
End Sub
Private Sub cmdFunc_Click()
Dim strResult As String
strResult = ""
Dim i As Integer
AryInit
For i = 0 To 41
strResult = strResult & CharCode(i, 0) & Space(5) & CharCode(i, 1) & vbCrLf
Next
txtValue.Text = strResult
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -