📄 adduser.frm
字号:
VERSION 5.00
Begin VB.Form adduser
Caption = "用户添加"
ClientHeight = 2790
ClientLeft = 60
ClientTop = 450
ClientWidth = 6300
LinkTopic = "Form1"
MaxButton = 0 'False
ScaleHeight = 2790
ScaleWidth = 6300
StartUpPosition = 2 'CenterScreen
Begin VB.CommandButton Command3
Caption = "退出"
Height = 495
Left = 4320
TabIndex = 11
Top = 2160
Width = 1215
End
Begin VB.Frame Frame1
Caption = "用户信息"
Height = 1935
Left = 120
TabIndex = 2
Top = 120
Width = 6015
Begin VB.TextBox Text3
Height = 300
IMEMode = 3 'DISABLE
Left = 1560
PasswordChar = "*"
TabIndex = 10
Top = 1440
Width = 1455
End
Begin VB.TextBox Text2
Height = 300
IMEMode = 3 'DISABLE
Left = 4440
PasswordChar = "*"
TabIndex = 9
Top = 465
Width = 1455
End
Begin VB.TextBox Text1
Height = 300
Left = 1560
TabIndex = 8
Top = 465
Width = 1455
End
Begin VB.ComboBox Combo1
Height = 300
ItemData = "adduser.frx":0000
Left = 4440
List = "adduser.frx":000D
TabIndex = 7
Top = 1320
Width = 1455
End
Begin VB.Label Label5
AutoSize = -1 'True
Caption = "用户权限"
Height = 180
Left = 3240
TabIndex = 6
Top = 1440
Width = 720
End
Begin VB.Label Label3
AutoSize = -1 'True
Caption = "密码确认"
Height = 180
Left = 360
TabIndex = 5
Top = 1440
Width = 720
End
Begin VB.Label Label2
AutoSize = -1 'True
Caption = "密码"
Height = 180
Left = 3240
TabIndex = 4
Top = 480
Width = 360
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "用户名"
Height = 180
Left = 360
TabIndex = 3
Top = 555
Width = 540
End
End
Begin VB.CommandButton Command2
Caption = "取消"
Height = 495
Left = 2760
TabIndex = 1
Top = 2160
Width = 1215
End
Begin VB.CommandButton Command1
Caption = "确认"
Height = 495
Left = 1200
TabIndex = 0
Top = 2160
Width = 1215
End
End
Attribute VB_Name = "adduser"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim mrc As ADODB.Recordset
txtsql = "select * from 权限表"
Set mrc = exesql(txtsql)
If Trim(Text2) = Trim(Text3) Then
mrc.AddNew
mrc.Fields("用户名") = Text1
mrc.Fields("密码") = Text2
mrc.Fields("所有权限") = Combo1.Text
mrc.Update
mrc.Close
End If
Text1 = ""
Text2 = ""
Text3 = ""
Combo1.Text = ""
End Sub
Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Combo1.Text = ""
End Sub
Private Sub Command3_Click()
Unload Me
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -