📄 frmmanagr.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
Begin VB.Form FrmManage
Caption = "系统设置"
ClientHeight = 5100
ClientLeft = 60
ClientTop = 345
ClientWidth = 6885
Icon = "FrmManagr.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 5100
ScaleWidth = 6885
StartUpPosition = 2 '屏幕中心
Begin MSAdodcLib.Adodc Adodc1
Height = 330
Left = 240
Top = 4560
Width = 1215
_ExtentX = 2143
_ExtentY = 582
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 = "Adodc1"
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.CheckBox Check1
Caption = "允许修改"
Enabled = 0 'False
ForeColor = &H00800080&
Height = 255
Left = 1920
TabIndex = 14
Top = 4600
Width = 1215
End
Begin VB.CommandButton Command3
Caption = "清空日志"
Enabled = 0 'False
Height = 375
Left = 4320
TabIndex = 11
Top = 4560
Width = 1095
End
Begin VB.Frame Frame1
Caption = "登录者属性"
Height = 2175
Left = 120
TabIndex = 0
Top = 120
Width = 6615
Begin VB.Frame Frame2
Height = 1935
Left = 4080
TabIndex = 12
Top = 120
Width = 2415
Begin VB.Label Label5
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "说明:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00800000&
Height = 210
Left = 120
TabIndex = 13
Top = 240
Width = 630
End
End
Begin VB.CommandButton Command1
Caption = "确定"
Height = 375
Left = 2880
TabIndex = 10
Top = 480
Width = 855
End
Begin VB.CommandButton Command2
Caption = "取消"
Height = 375
Left = 2880
TabIndex = 9
Top = 1320
Width = 855
End
Begin VB.TextBox Text4
Height = 270
IMEMode = 3 'DISABLE
Left = 1320
MaxLength = 12
PasswordChar = "*"
TabIndex = 8
Top = 1680
Width = 1335
End
Begin VB.TextBox Text3
Height = 270
IMEMode = 3 'DISABLE
Left = 1320
MaxLength = 12
PasswordChar = "*"
TabIndex = 7
Top = 1200
Width = 1335
End
Begin VB.TextBox Text2
Enabled = 0 'False
Height = 270
IMEMode = 3 'DISABLE
Left = 1320
MaxLength = 12
PasswordChar = "*"
TabIndex = 6
Top = 720
Width = 1335
End
Begin VB.TextBox Text1
Enabled = 0 'False
ForeColor = &H00C00000&
Height = 270
Left = 1320
TabIndex = 5
Top = 300
Width = 1335
End
Begin VB.Label Label4
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "确认密码:"
Height = 180
Left = 360
TabIndex = 4
Top = 1800
Width = 900
End
Begin VB.Label Label3
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "更新密码:"
Height = 180
Left = 360
TabIndex = 3
Top = 1320
Width = 900
End
Begin VB.Label Label2
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "登录密码:"
Height = 180
Left = 360
TabIndex = 2
Top = 840
Width = 900
End
Begin VB.Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "登录姓名:"
Height = 180
Left = 360
TabIndex = 1
Top = 360
Width = 900
End
End
Begin MSDataGridLib.DataGrid DataGrid1
Bindings = "FrmManagr.frx":030A
Height = 1695
Left = 120
TabIndex = 15
Top = 2640
Width = 6615
_ExtentX = 11668
_ExtentY = 2990
_Version = 393216
AllowUpdate = 0 'False
HeadLines = 1
RowHeight = 15
FormatLocked = -1 'True
BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ColumnCount = 5
BeginProperty Column00
DataField = "时间"
Caption = "时间"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column01
DataField = "错误窗口"
Caption = "错误窗口"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column02
DataField = "错误代号"
Caption = "错误代号"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column03
DataField = "错误源"
Caption = "错误源"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column04
DataField = "错误提示"
Caption = "错误提示"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
SplitCount = 1
BeginProperty Split0
BeginProperty Column00
ColumnWidth = 1230.236
EndProperty
BeginProperty Column01
ColumnWidth = 1814.74
EndProperty
BeginProperty Column02
ColumnWidth = 1275.024
EndProperty
BeginProperty Column03
ColumnWidth = 2085.166
EndProperty
BeginProperty Column04
ColumnWidth = 2085.166
EndProperty
EndProperty
End
End
Attribute VB_Name = "FrmManage"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim CmdExe As ADODB.Command
Private Sub Check1_Click()
If Check1.Value = 1 Then
DataGrid1.AllowUpdate = True
DataGrid1.AllowDelete = True
Else
DataGrid1.AllowUpdate = False
DataGrid1.AllowDelete = False
End If
End Sub
Private Sub Command1_Click()
If Text3.Text = Text4.Text And Text3.Text <> "" Then
CmdExe.CommandText = "UPDATE 分工表 SET 密码 = '" & Text3.Text & "' WHERE 班主任='" & Text1.Text & "'"
CmdExe.Execute
MsgBox Text1.Text & ",您的密码已被成功更改!", , "密码更改:"
Else
MsgBox "更改密码与确认密码不相符或空!"
End If
Text3.Text = ""
Text4.Text = ""
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Command4_Click()
End Sub
Private Sub Command3_Click()
CmdExe.CommandText = "delete * from 日志表"
CmdExe.Execute
DataGrid1.Refresh
End Sub
Private Sub Form_Activate()
If Text1.Text = "Administrator" Then
Text3.Enabled = False
Text4.Enabled = False
Command1.Enabled = False
Command3.Enabled = True
Check1.Enabled = True
Else
Text3.Enabled = True
Text4.Enabled = True
Command1.Enabled = True
Command3.Enabled = False
Check1.Enabled = False
End If
End Sub
Private Sub Form_Load()
Text1.Text = UserName
Text2.Text = Permission
Set CmdExe = New ADODB.Command
CmdExe.ActiveConnection = Con
With Adodc1
.ConnectionString = Con.ConnectionString
.CommandType = adCmdTable
.RecordSource = "日志表"
End With
Adodc1.Refresh
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -