📄 frm4systemset.frm
字号:
VERSION 5.00
Begin VB.Form frmSystemSet
BorderStyle = 1 'Fixed Single
Caption = "系统环境设置"
ClientHeight = 1965
ClientLeft = 2460
ClientTop = 4575
ClientWidth = 4605
ControlBox = 0 'False
BeginProperty Font
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
HelpContextID = 9003
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1965
ScaleWidth = 4605
StartUpPosition = 2 'CenterScreen
Begin VB.TextBox Text4SaPwd
Height = 360
IMEMode = 3 'DISABLE
Left = 1680
PasswordChar = "*"
TabIndex = 1
Top = 600
Width = 2655
End
Begin VB.TextBox Text4ValidateSa
Height = 360
IMEMode = 3 'DISABLE
Left = 1680
PasswordChar = "*"
TabIndex = 2
Top = 1020
Width = 2655
End
Begin VB.CommandButton Command4Cancel
Caption = "取消(&C)"
Height = 360
Left = 2580
TabIndex = 4
Top = 1500
Width = 1440
End
Begin VB.CommandButton Command4OK
Caption = "确定(&O)"
Height = 360
Left = 660
TabIndex = 3
Top = 1500
Width = 1440
End
Begin VB.TextBox Text4ServerName
Height = 360
Left = 1680
TabIndex = 0
Top = 150
Width = 2655
End
Begin VB.Label Label1
Alignment = 1 'Right Justify
Caption = "数据库sa密码"
Height = 315
Index = 1
Left = 180
TabIndex = 7
Top = 600
Width = 1155
End
Begin VB.Label Label2
Alignment = 1 'Right Justify
Caption = "验证sa密码"
Height = 255
Index = 1
Left = 120
TabIndex = 6
Top = 1080
Width = 1215
End
Begin VB.Label Label2
Caption = "服务器名"
Height = 180
Index = 0
Left = 600
TabIndex = 5
Top = 210
Width = 735
End
End
Attribute VB_Name = "frmSystemSet"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private m_bisLogin As Boolean
Private Sub Command4Cancel_Click()
g_bIsInitSystemSet = False
Unload Me
End Sub
Private Sub Command4OK_Click()
If Trim(Me.Text4SaPwd.text) <> Trim(Me.Text4ValidateSa.text) Then
MsgBox "请输入相同的数据库sa密码", vbOKOnly, "警告"
Exit Sub
End If
g_str4ServerName = Text4ServerName.text
g_str4Password = g_saEncry.Encrypt(Me.Text4SaPwd.text)
g_strOprrolePassword = g_saEncry.Encrypt(g_strOprrolePassword)
If WriteConfigMsg = 0 Then
g_str4Password = Me.Text4SaPwd.text
g_strOprrolePassword = g_saEncry.Decrypt(g_strOprrolePassword)
g_bIsInitSystemSet = True
If m_bisLogin = False Then MsgBox "重新进入程序配置才生效", vbOKOnly, "提示"
Unload Me
Else
g_strOprrolePassword = g_saEncry.Decrypt(g_strOprrolePassword)
MsgBox "写配置错误。", vbOKOnly, "配置错误"
Text4ServerName.SetFocus
End If
End Sub
Private Sub Form_Load()
If g_bIsInitSystemSet = False Then m_bisLogin = True
Text4ServerName.text = g_str4ServerName
Text4SaPwd.text = g_str4Password
Me.Text4ValidateSa.text = g_str4Password
Text4ServerName.Tag = g_str4ServerName
Text4SaPwd.Tag = g_str4Password
Me.Text4ValidateSa.Tag = g_str4Password
End Sub
Private Sub Form_Unload(Cancel As Integer)
If g_bIsInitSystemSet = False Then
g_str4ServerName = Text4ServerName.Tag
g_str4Password = Text4SaPwd.Tag
End If
If m_bisLogin = False Then MDIfrmMain.SSActiveToolBarsMain.Tools("ID_系统环境设置").Enabled = True
End Sub
Private Sub Text4ValidateSa_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then Command4OK_Click
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -