📄 main_mima.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
Begin VB.Form main_mima
BackColor = &H00808080&
BorderStyle = 1 'Fixed Single
Caption = "客户管理系统"
ClientHeight = 2700
ClientLeft = 3240
ClientTop = 4230
ClientWidth = 5805
Icon = "main_mima.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
Picture = "main_mima.frx":030A
ScaleHeight = 2700
ScaleWidth = 5805
StartUpPosition = 1 'CenterOwner
Begin VB.TextBox Text2
Height = 375
IMEMode = 3 'DISABLE
Left = 2280
PasswordChar = "*"
TabIndex = 5
Top = 1080
Width = 1935
End
Begin VB.ComboBox Combo1
Height = 300
Left = 2280
TabIndex = 4
Top = 600
Width = 1935
End
Begin VB.CommandButton Cmd2
BackColor = &H00FF8080&
Caption = "退出"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 400
Left = 3015
Style = 1 'Graphical
TabIndex = 1
Top = 1965
Width = 1000
End
Begin VB.CommandButton Cmd1
BackColor = &H00FF8080&
Caption = "确定"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 400
Left = 1800
MaskColor = &H00FF8080&
Style = 1 'Graphical
TabIndex = 0
Top = 1965
UseMaskColor = -1 'True
Width = 1000
End
Begin MSAdodcLib.Adodc Adodc1
Height = 375
Left = 240
Top = 2760
Visible = 0 'False
Width = 1560
_ExtentX = 2752
_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=Microsoft.Jet.OLEDB.4.0;Data Source=khgl.mdb;Persist Security Info=False"
OLEDBString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=khgl.mdb;Persist Security Info=False"
OLEDBFile = ""
DataSourceName = ""
OtherAttributes = ""
UserName = ""
Password = ""
RecordSource = "select * from ma"
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.Label Label2
BackStyle = 0 'Transparent
Caption = "密 码: "
BeginProperty Font
Name = "黑体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 300
Left = 1440
TabIndex = 3
Top = 1110
Width = 855
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "操作员: "
BeginProperty Font
Name = "黑体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 405
Left = 1440
TabIndex = 2
Top = 630
Width = 1095
End
End
Attribute VB_Name = "main_mima"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Combo1_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Text2.SetFocus
Else
End If
End Sub
Private Sub Form_Activate()
Combo1.SetFocus
End Sub
Private Sub Form_Load()
Adodc1.RecordSource = "select * from ma "
Adodc1.Refresh
If Adodc1.Recordset.RecordCount > 0 Then
Do While Adodc1.Recordset.EOF = False
Combo1.AddItem (Adodc1.Recordset.Fields("操作员"))
Adodc1.Recordset.MoveNext
Loop
Else
End If
End Sub
Private Sub cmd1_Click()
Adodc1.RecordSource = "select * from ma where 操作员='" + Combo1.Text + "'and 密码='" + Text2.Text + "'"
Adodc1.Refresh
If Adodc1.Recordset.RecordCount > 0 Then
Frm_main.Check1.Value = Adodc1.Recordset.Fields("基本信息管理")
Frm_main.Check2.Value = Adodc1.Recordset.Fields("客户信息管理")
Frm_main.Check3.Value = Adodc1.Recordset.Fields("客户信息查询")
Frm_main.Check4.Value = Adodc1.Recordset.Fields("系统设置")
Load Frm_main
Frm_main.Show
Unload Me
Else
MsgBox "没有此操作员的信息或者输入的密码错误,请您确认后重新输入"
Combo1.Text = ""
Text2.Text = ""
Combo1.SetFocus
End If
End Sub
Private Sub cmd2_Click()
End
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -