📄 frmmodifypwd.frm
字号:
VERSION 5.00
Begin VB.Form frmModifypwd
BorderStyle = 3 'Fixed Dialog
Caption = "Modify password"
ClientHeight = 2925
ClientLeft = 45
ClientTop = 435
ClientWidth = 4680
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 2925
ScaleWidth = 4680
ShowInTaskbar = 0 'False
StartUpPosition = 3 'Windows Default
Begin VB.CommandButton cmdCancel
Caption = "Cancel"
Height = 495
Left = 2880
TabIndex = 5
Top = 2160
Width = 1095
End
Begin VB.CommandButton cmdOK
Caption = "OK"
Height = 495
Left = 720
TabIndex = 4
Top = 2160
Width = 1095
End
Begin VB.TextBox Text1
Height = 375
Index = 2
Left = 2040
MaxLength = 100
TabIndex = 3
Top = 1320
Width = 2295
End
Begin VB.TextBox Text1
Height = 375
Index = 1
Left = 2040
MaxLength = 100
TabIndex = 2
Top = 480
Width = 2295
End
Begin VB.Label Label2
Caption = "Confirm New Password:"
ForeColor = &H8000000D&
Height = 495
Left = 120
TabIndex = 1
Top = 1320
Width = 1695
End
Begin VB.Label Label1
Caption = "New Password:"
ForeColor = &H8000000D&
Height = 495
Left = 600
TabIndex = 0
Top = 600
Width = 1575
End
End
Attribute VB_Name = "frmModifypwd"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub cmdCancel_Click()
Unload Me
End Sub
Private Sub cmdOK_Click()
Dim txtSQL, MsgText As String
Dim mrc As ADODB.Recordset
If Trim(Text1(1).Text) <> Trim(Text1(2).Text) Then
MsgBox "密码输入不正确!", vbOKOnly + vbExclamation, "警告"
Text1(1).SetFocus
Text1(1).Text = ""
Else
txtSQL = "select * from UserTable where User_id = '" & UserName & "'"
Set mrc = ExecuteSQL(txtSQL, MsgText)
mrc.Fields(1) = Text1(1).Text
mrc.Update
mrc.Close
MsgBox "密码修改成功!", vbOKOnly + vbExclamation, "修改密码"
Me.Hide
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -