📄 frmmain.frm
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
Begin VB.MDIForm frmMain
BackColor = &H8000000C&
Caption = "Management System"
ClientHeight = 4950
ClientLeft = 165
ClientTop = 1155
ClientWidth = 6690
LinkTopic = "MDIForm1"
StartUpPosition = 3 'Windows Default
Begin MSComctlLib.StatusBar sbStatusBar
Align = 2 'Align Bottom
Height = 270
Left = 0
TabIndex = 0
Top = 4680
Width = 6690
_ExtentX = 11800
_ExtentY = 476
_Version = 393216
BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628}
NumPanels = 3
BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628}
AutoSize = 1
Object.Width = 6138
Text = "Status"
TextSave = "Status"
EndProperty
BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 6
AutoSize = 2
TextSave = "12/30/2004"
EndProperty
BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 5
AutoSize = 2
TextSave = "3:17 PM"
EndProperty
EndProperty
End
Begin VB.Menu menuSystem
Caption = "System"
Begin VB.Menu menuAdduser
Caption = "Add User"
End
Begin VB.Menu menuModifypwd
Caption = "Modifiy Password"
End
Begin VB.Menu menuExit
Caption = "Exit"
End
End
Begin VB.Menu menuManrecord
Caption = "Employee Information"
Begin VB.Menu menuAddrecord
Caption = "Add employee information"
End
Begin VB.Menu menuModifyrecord
Caption = "Modify Employee Information"
End
Begin VB.Menu menuDelete
Caption = "Delete Employee Information"
End
End
Begin VB.Menu menuProject
Caption = "Projects"
Begin VB.Menu menuAddproject
Caption = "Add New Project"
End
Begin VB.Menu menuModifyproject
Caption = "Modify Project"
End
Begin VB.Menu menuDeleteproject
Caption = "Delete Project"
End
End
Begin VB.Menu menuCheck
Caption = "Attendance Information"
Begin VB.Menu menuAddcheck
Caption = "Add Attendance Information"
End
Begin VB.Menu menuModifychek
Caption = "Modify Attendance Information"
End
Begin VB.Menu menuDeletecheck
Caption = "Delete Attendance Information"
End
End
Begin VB.Menu menuBasic
Caption = "Basic Information"
Begin VB.Menu menuBaseinfo
Caption = "Add Base Information"
End
Begin VB.Menu menuModifybase
Caption = "Modify Base Information"
Enabled = 0 'False
End
Begin VB.Menu menuDeletebase
Caption = "Delete Base Information"
Enabled = 0 'False
End
End
Begin VB.Menu menuManapprise
Caption = "Tools"
Begin VB.Menu menuCreatechart
Caption = "Create Table"
Begin VB.Menu menuCheckchart
Caption = "Create Check Table"
End
End
Begin VB.Menu menuCreatediagram
Caption = "Create Workhours Chart"
End
End
Begin VB.Menu menuHelp
Caption = "Help"
Begin VB.Menu menuAbout
Caption = "About"
End
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub MDIForm_Load()
Me.Left = GetSetting(App.TITLE, "Settings", "MainLeft", 1000)
Me.Top = GetSetting(App.TITLE, "Settings", "MainTop", 1000)
Me.Width = GetSetting(App.TITLE, "Settings", "MainWidth", 6500)
Me.Height = GetSetting(App.TITLE, "Settings", "MainHeight", 6500)
flagEdit = False
End Sub
Private Sub MDIForm_Unload(Cancel As Integer)
If Me.WindowState <> vbMinimized Then
SaveSetting App.TITLE, "Settings", "MainLeft", Me.Left
SaveSetting App.TITLE, "Settings", "MainTop", Me.Top
SaveSetting App.TITLE, "Settings", "MainWidth", Me.Width
SaveSetting App.TITLE, "Settings", "MainHeight", Me.Height
End If
Unload Me
End Sub
Private Sub menuAbout_Click()
gintMode = 1
frmAbout.Show
frmAbout.ZOrder 0
End Sub
Private Sub menuAddapprise_Click()
gintMode = 1
frmManApp1.Show
frmManApp1.ZOrder 0
End Sub
Private Sub menuAddcheck_Click()
Dim i As Integer
gintMode = 1
frmCheckinfo.Show
frmCheckinfo.ZOrder 0
'刷新
' frmCheckinfo.txtItem(0).Text = ""
' frmCheckinfo.txtItem(1).Text = ""
' frmCheckinfo.txtItem(2).Text = ""
' frmCheckinfo.txtItem(3).Text = ""
' frmCheckinfo.Text1.Text = ""
' For i = 1 To frmCheckinfo.msgList.Rows - 1
'
' frmCheckinfo.msgList.TextMatrix(i, 1) = ""
' Next i
End Sub
Private Sub menuAddpay_Click()
gintMode = 1
frmPay1.Show
frmPay1.ZOrder 0
End Sub
Private Sub menuAddproject_Click()
gintMode = 1
frmManApp1.Show
frmManApp1.ZOrder 0
End Sub
Private Sub menuAddrecord_Click()
gintMode = 1
frmManRecord1.Show
frmManRecord1.ZOrder 0
End Sub
Private Sub menuAdduser_Click()
frmAdduser.Show
sbStatusBar.Panels(1).Text = "添加用户"
End Sub
Private Sub menuBaseinfo_Click()
gintMode = 1
frmBasic1.Show
frmBasic1.ZOrder 0
End Sub
Private Sub menuCheckchart_Click()
gintMode = 1
frmCheckChart.Show
frmCheckChart.ZOrder 0
End Sub
Private Sub menuCreatediagram_Click()
frmChart1.Show
frmChart1.ZOrder 0
End Sub
Private Sub menuCreatereportforms_Click()
DataReport1.Show
'填充相应字段
' DataReport1.Sections(4).Controls("Label1").Caption = "入库单据"
'DataReport1.Sections(2).Controls("Label2").Caption = CStr(dcbProduct.Text)
'DataReport1.Sections(2).Controls("Label3").Caption = "数量:" & CStr(txtAmount.Text)
'DataReport1.Sections(2).Controls("Label4").Caption = "供应商:" & CStr(dcbProvider.Text)
'DataReport1.Sections(2).Controls("Label5").Caption = "单价:" & CStr(txtPrice.Text)
'DataReport1.Sections(2).Controls("Label6").Caption = "经手人:" & CStr(dcbEmployee.Text)
'DataReport1.Sections(2).Controls("Label7").Caption = "时间:" & CStr(Date) & " " & CStr(Time) & " " & CStr(adcIn.Recordset("InID"))
'禁止打印按钮
'asPopup4.Enabled = False
End Sub
Private Sub menuDelete_Click()
Dim txtSQL As String
Dim MsgText As String
Dim intCount As Integer
Dim mrc As ADODB.Recordset
If flagEdit Then
If frmManRecord.msgList.Rows > 1 Then
If MsgBox("真的要删除这条文件记录么?", vbOKCancel + vbExclamation, "警告") = vbOK Then
intCount = frmManRecord.msgList.Row
txtSQL = "delete from EmployeeTable where Em_id='" & Trim(frmManRecord.msgList.TextMatrix(frmManRecord.msgList.Row, 1)) & "'"
Set mrc = ExecuteSQL(txtSQL, MsgText)
frmManRecord.txtSQL = "select * from EmployeeTable"
flagEdit = True
frmManRecord.ShowTitle
frmManRecord.Showdata
End If
End If
Else
MsgBox "请选择要删除的记录?", vbOKOnly + vbExclamation, "警告"
frmManRecord.txtSQL = "select * from EmployeeTable"
frmManRecord.Show
frmManRecord.ZOrder 0
End If
End Sub
Private Sub menuDeleteapprise_Click()
Dim txtSQL As String
Dim MsgText As String
Dim intCount As Integer
Dim mrc As ADODB.Recordset
If flagEdit Then
If frmManApp.msgList.Rows > 1 Then
If MsgBox("真的要删除这条文件记录么?", vbOKCancel + vbExclamation, "警告") = vbOK Then
intCount = frmManApp.msgList.Row
txtSQL = "delete from manappraise where pjno='" & Trim(frmManApp.msgList.TextMatrix(frmManApp.msgList.Row, 1)) & "'"
Set mrc = ExecuteSQL(txtSQL, MsgText)
frmManApp.txtSQL = "select pjno,pjdept,pjid,pjname,pjdate,pjresult,pjposition,pjlevel,pjother1,pjother2,pjremark from manappraise"
flagEdit = True
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -