📄 main_xtgl_czy.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
Begin VB.Form main_xtgl_czy
BorderStyle = 3 'Fixed Dialog
Caption = "系统管理-【操作员】"
ClientHeight = 3150
ClientLeft = 2715
ClientTop = 3690
ClientWidth = 6525
Icon = "main_xtgl_czy.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 3150
ScaleWidth = 6525
ShowInTaskbar = 0 'False
StartUpPosition = 1 '所有者中心
Begin MSAdodcLib.Adodc Ado_Update
Height = 570
Left = 1380
Top = 5175
Width = 2205
_ExtentX = 3889
_ExtentY = 1005
ConnectMode = 0
CursorLocation = 3
IsolationLevel = -1
ConnectionTimeout= 15
CommandTimeout = 30
CursorType = 3
LockType = 3
CommandType = 8
CursorOptions = 0
CacheSize = 50
MaxRecords = 0
BOFAction = 0
EOFAction = 0
ConnectStringType= 1
Appearance = 1
BackColor = -2147483643
ForeColor = -2147483640
Orientation = 0
Enabled = -1
Connect = ""
OLEDBString = ""
OLEDBFile = ""
DataSourceName = ""
OtherAttributes = ""
UserName = ""
Password = ""
RecordSource = ""
Caption = "Ado_Update"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
_Version = 393216
End
Begin VB.CommandButton Command2
Caption = "取消"
Height = 390
Left = 3360
Picture = "main_xtgl_czy.frx":038A
TabIndex = 1
Top = 2640
Width = 1575
End
Begin VB.CommandButton Command1
Caption = "确定"
Height = 390
Left = 1605
Picture = "main_xtgl_czy.frx":1D44
TabIndex = 0
Tag = "设置操作员"
Top = 2640
Width = 1575
End
Begin VB.Frame Frame1
Height = 2535
Left = 30
TabIndex = 2
Top = -60
Width = 6465
Begin VB.TextBox Text1
BackColor = &H00FFFFFF&
Height = 315
IMEMode = 3 'DISABLE
Index = 2
Left = 2115
PasswordChar = "*"
TabIndex = 7
Top = 1845
Width = 2880
End
Begin VB.TextBox Text1
BackColor = &H00FFFFFF&
Height = 315
IMEMode = 3 'DISABLE
Index = 1
Left = 2115
PasswordChar = "*"
TabIndex = 6
Top = 1305
Width = 2880
End
Begin VB.TextBox Text1
BackColor = &H00FFFFFF&
Height = 315
Index = 0
Left = 2115
TabIndex = 3
Top = 765
Width = 2880
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "请输入操作员及密码"
ForeColor = &H000000FF&
Height = 225
Left = 180
TabIndex = 5
Top = 315
Width = 4290
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "操作员 密 码 确认密码"
Height = 1365
Left = 1260
TabIndex = 4
Top = 840
Width = 765
End
End
End
Attribute VB_Name = "main_xtgl_czy"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'*************************************************************************
'**模 块 名:main_xtgl_czy
'**版权说明:吉林省明日科技有限公司享有本软件的所有版权,如果本软件用于商
'** 业用途,必须经过吉林省明日科技有限公司授权。如果提供网上免费
'** 下载,必须经过吉林省明日科技有限公司授权,并保证程序的完整,
'** 不得修改代码、注释和相关内容,否则,我公司将追究其法律责任
'**网 址:www.mingrisoft.com 价值无限,服务无限
'**电 话:(0431)84978981,84978982
'**创 建 人:明日科技
'**日 期:2007-10-31
'**修 改 人:MRLBB
'**日 期:2007-10-31
'**描 述:
'*************************************************************************
Private Sub Form_Activate()
Text1(0).SetFocus
End Sub
Private Sub Form_Load()
Ado_Update.ConnectionString = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=db_JXC;Data Source=."
End Sub
Private Sub text1_GotFocus(Index As Integer)
Text1(Index).BackColor = &HFFFF80
Text1(Index).SelStart = 0
Text1(Index).SelLength = Len(Text1(Index))
End Sub
Private Sub text1_LostFocus(Index As Integer)
Text1(Index).BackColor = &HFFFFFF
End Sub
Private Sub Text1_KeyDown(Index As Integer, KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyReturn And Index < 2 Then Text1(Index + 1).SetFocus
If KeyCode = vbKeyReturn And Index = 2 Then Command1.SetFocus
If KeyCode = vbKeyUp And Index > 0 Then Text1(Index - 1).SetFocus
End Sub
Private Sub Command1_Click() '确认修改操作员信息
Dim rs1 As New ADODB.Recordset
If Len(Text1(0)) = 0 Then
MsgBox "请输入操作员!"
Exit Sub
End If
If Len(Text1(1)) = 0 Then
MsgBox "请输入密码!"
Exit Sub
End If
If Len(Text1(2)) = 0 Then
MsgBox "请输入确认密码!"
Exit Sub
End If
If Text1(1) <> Text1(2) Then
MsgBox "输入的密码与确认密码不一致!"
Exit Sub
End If
rs1.Open "tb_power", Cnn, adOpenStatic '查询操作员信息
Ado_Update.RecordSource = "select * from tb_power"
Ado_Update.Refresh
Ado_Update.Recordset.AddNew
Ado_Update.Recordset.Fields("操作员") = Text1(0)
Ado_Update.Recordset.Fields("密码") = Text1(1)
Ado_Update.Recordset.Update
main_xtgl_czqx.ado1.Refresh
RegInfo Me
Unload Me
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -