⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frmchangepassword.frm

📁 本公司开发得大请油田人事管理系统c/s结构
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frmChangePassword 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "改变密码"
   ClientHeight    =   2475
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   4680
   HelpContextID   =   1021
   Icon            =   "frmChangePassword.frx":0000
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   2475
   ScaleWidth      =   4680
   ShowInTaskbar   =   0   'False
   StartUpPosition =   2  'CenterScreen
   Begin VB.CommandButton Command4Cancel 
      Caption         =   "取消(&C)"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   360
      Left            =   2640
      TabIndex        =   7
      Top             =   1920
      Width           =   1440
   End
   Begin VB.TextBox TextOldPwd 
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      IMEMode         =   3  'DISABLE
      Left            =   2033
      PasswordChar    =   "*"
      TabIndex        =   0
      Top             =   270
      Width           =   1935
   End
   Begin VB.CommandButton Command4OK 
      Caption         =   "确定(&O)"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   360
      Left            =   600
      TabIndex        =   4
      Top             =   1920
      Width           =   1440
   End
   Begin VB.TextBox TextNewPwd 
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      IMEMode         =   3  'DISABLE
      Left            =   2033
      MaxLength       =   12
      PasswordChar    =   "*"
      TabIndex        =   2
      Top             =   750
      Width           =   1935
   End
   Begin VB.TextBox TextVerifyNewPwd 
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      IMEMode         =   3  'DISABLE
      Left            =   2033
      MaxLength       =   12
      PasswordChar    =   "*"
      TabIndex        =   3
      Top             =   1230
      Width           =   1935
   End
   Begin VB.Label Label3 
      Caption         =   "校验新密码"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   195
      Left            =   713
      TabIndex        =   6
      Top             =   1230
      Width           =   975
   End
   Begin VB.Label Label2 
      Caption         =   "    新密码"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   195
      Left            =   713
      TabIndex        =   5
      Top             =   750
      Width           =   975
   End
   Begin VB.Label Label1 
      Caption         =   "    旧密码"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   195
      Left            =   713
      TabIndex        =   1
      Top             =   270
      Width           =   975
   End
End
Attribute VB_Name = "frmChangePassword"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Attribute VB_HelpID = 6000
Attribute VB_Ext_KEY = "RVB_UniqueId" ,"396AB9C901C6"
Attribute VB_Ext_KEY = "RVB_ModelStereotype" ,"Form"
Option Explicit
Dim m_strSQL As String

Private Sub Command4Cancel_Click()
    Unload Me
End Sub

Private Sub Command4OK_Click()
    If TextOldPwd.text <> g_strOprrolePassword Then
        MsgBox "旧密码不对 !", vbOKOnly, "提示"
        Exit Sub
    End If
    If TextNewPwd.text <> TextVerifyNewPwd.text Then
        MsgBox "两个新密码不相同 !", vbOKOnly, "提示"
        TextNewPwd.SetFocus
        Exit Sub
    End If
    If g_lOprroleNo = 0 Then
        g_strOprrolePassword = g_saEncry.Encrypt(TextNewPwd.text)
        g_str4Password = g_saEncry.Encrypt(g_str4Password)
        If WriteConfigMsg = 0 Then
            g_strOprrolePassword = TextNewPwd.text
            g_str4Password = g_saEncry.Decrypt(g_str4Password)
        Else
            g_str4Password = g_saEncry.Decrypt(g_str4Password)
            MsgBox "写配置错误。", vbOKOnly, "配置错误"
            Exit Sub
        End If
    Else
        m_strSQL = "update T_EMP_BASIC set EMP_PASSWORD='" & TextNewPwd.text & "' from T_EMP_BASIC where EMP_NO=" & g_lEmpNo
        ExcuteSQL m_strSQL
    End If
    MsgBox "密码已经成功改变", vbOKOnly, "成功"
    Unload Me
End Sub

Private Sub Form_Load()
    Unload frmSplash
End Sub

Private Sub Form_Unload(Cancel As Integer)
    MDIfrmMain.SSActiveToolBarsMain.Tools("ID_用户口令变更").Enabled = True
End Sub


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -