📄 forpassw.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "msadodc.ocx"
Begin VB.Form ForPassw
Caption = "设置密码"
ClientHeight = 4815
ClientLeft = 60
ClientTop = 435
ClientWidth = 7110
BeginProperty Font
Name = "MS Sans Serif"
Size = 12
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
LinkTopic = "Form1"
ScaleHeight = 4815
ScaleWidth = 7110
StartUpPosition = 2 'CenterScreen
Begin MSAdodcLib.Adodc Adodc1
Height = 375
Left = 2280
Top = 240
Visible = 0 'False
Width = 1200
_ExtentX = 2117
_ExtentY = 661
ConnectMode = 0
CursorLocation = 3
IsolationLevel = -1
ConnectionTimeout= 15
CommandTimeout = 30
CursorType = 3
LockType = 3
CommandType = 1
CursorOptions = 0
CacheSize = 50
MaxRecords = 0
BOFAction = 0
EOFAction = 0
ConnectStringType= 1
Appearance = 1
BackColor = -2147483643
ForeColor = -2147483640
Orientation = 0
Enabled = -1
Connect = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=train"
OLEDBString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=train"
OLEDBFile = ""
DataSourceName = ""
OtherAttributes = ""
UserName = ""
Password = ""
RecordSource = "select * from 用户信息表"
Caption = "Adodc1"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "MS Sans Serif"
Size = 12
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
_Version = 393216
End
Begin VB.CommandButton Command2
BackColor = &H00FF80FF&
Caption = "返回"
Height = 495
Left = 5520
Style = 1 'Graphical
TabIndex = 11
Top = 3240
Width = 1455
End
Begin VB.CommandButton Command1
BackColor = &H00FF80FF&
Caption = "确定"
Height = 495
Left = 5520
Style = 1 'Graphical
TabIndex = 10
Top = 1560
Width = 1455
End
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
BackColor = &H80000005&
BorderStyle = 0 'None
ForeColor = &H80000008&
Height = 495
Left = 120
Picture = "ForPassw.frx":0000
ScaleHeight = 495
ScaleWidth = 495
TabIndex = 9
Top = 120
Width = 495
End
Begin VB.Frame Frame1
BackColor = &H0080C0FF&
Caption = "****************************************************************************"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 3015
Index = 0
Left = 840
TabIndex = 1
Top = 960
Width = 4455
Begin VB.TextBox Text4
BackColor = &H0080FFFF&
Height = 495
IMEMode = 3 'DISABLE
Left = 2160
PasswordChar = "*"
TabIndex = 16
Text = "Text4"
Top = 2160
Width = 1575
End
Begin VB.PictureBox Picture2
BackColor = &H00C0FFC0&
Height = 495
Index = 3
Left = 240
Picture = "ForPassw.frx":08CA
ScaleHeight = 435
ScaleWidth = 435
TabIndex = 15
Top = 2160
Width = 495
End
Begin VB.PictureBox Picture2
BackColor = &H00C0FFC0&
Height = 495
Index = 2
Left = 240
Picture = "ForPassw.frx":0BD4
ScaleHeight = 435
ScaleWidth = 435
TabIndex = 14
Top = 1560
Width = 495
End
Begin VB.PictureBox Picture2
BackColor = &H00C0FFC0&
Height = 495
Index = 1
Left = 240
Picture = "ForPassw.frx":0EDE
ScaleHeight = 435
ScaleWidth = 435
TabIndex = 13
Top = 960
Width = 495
End
Begin VB.PictureBox Picture2
BackColor = &H00C0FFC0&
Height = 495
Index = 0
Left = 240
Picture = "ForPassw.frx":11E8
ScaleHeight = 435
ScaleWidth = 435
TabIndex = 12
Top = 360
Width = 495
End
Begin VB.TextBox Text3
BackColor = &H0080FFFF&
Height = 540
IMEMode = 3 'DISABLE
Left = 2160
PasswordChar = "*"
TabIndex = 8
Text = "Text3"
Top = 1560
Width = 1575
End
Begin VB.TextBox Text2
BackColor = &H0080FFFF&
Height = 495
IMEMode = 3 'DISABLE
Left = 2160
PasswordChar = "*"
TabIndex = 7
Text = "Text2"
Top = 960
Width = 1575
End
Begin VB.TextBox Text1
BackColor = &H0080FFFF&
Height = 540
IMEMode = 3 'DISABLE
Left = 2160
TabIndex = 6
Text = "Text1"
Top = 360
Width = 1575
End
Begin VB.Label Label5
BackStyle = 0 'Transparent
Caption = "新密码"
Height = 375
Left = 1080
TabIndex = 5
Top = 2280
Width = 735
End
Begin VB.Label Label4
BackStyle = 0 'Transparent
Caption = "新密码"
Height = 375
Left = 1080
TabIndex = 4
Top = 1680
Width = 855
End
Begin VB.Label Label3
BackStyle = 0 'Transparent
Caption = "旧密码"
Height = 375
Left = 1080
TabIndex = 3
Top = 1080
Width = 855
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "用户名"
Height = 375
Left = 960
TabIndex = 2
Top = 480
Width = 855
End
End
Begin VB.Image Image1
Height = 11520
Left = -7440
Picture = "ForPassw.frx":14F2
Top = -360
Width = 15360
End
Begin VB.Label Label1
Caption = "Label1"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 135
Left = 480
TabIndex = 0
Top = 720
Width = 15
End
End
Attribute VB_Name = "ForPassw"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
If Text1.Text = "" Then
MsgBox "请输入用户名!!", vbYesNo + vbExclamation, "提示"
Text1.SetFocus
Exit Sub
End If
If Text2.Text <> ForLogin.txtPassword.Text Then
MsgBox "您输入的旧密码有误!请再次输入!!", vbYesNo + vbExclamation, "提示"
Text2.Text = ""
Text2.SetFocus
Exit Sub
End If
If Text3.Text <> Text4.Text Then
MsgBox "密码不一致!", vbYesNo + vbExclamation, "提示"
Text3.Text = ""
Text4.Text = ""
Text3.SetFocus
Text4.SetFocus
Exit Sub
End If
Adodc1.RecordSource = "select * from 用户信息表 where 用户密码='" & ForLogin.txtPassword.Text & "'"
Adodc1.Refresh
Adodc1.Recordset("用户密码") = Trim(Text3.Text)
Adodc1.Recordset.Update
Adodc1.Refresh
MsgBox "密码修改成功!!!", vbYesNo + vbExclamation, "提示"
Text2.Text = ""
Text3.Text = ""
Text4.Text = ""
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
Text1.Text = ForLogin.UserName
Text2.Text = ""
Text3.Text = ""
Text4.Text = ""
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -