📄 frm_main.frm
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Begin VB.Form frm_main
BackColor = &H80000018&
Caption = "图书馆管理系统"
ClientHeight = 9420
ClientLeft = 105
ClientTop = 105
ClientWidth = 14745
Icon = "frm_main.frx":0000
LinkTopic = "Form1"
ScaleHeight = 9420
ScaleWidth = 14745
StartUpPosition = 2 '屏幕中心
Begin MSComDlg.CommonDialog CommonDialog1
Left = 1320
Top = 6960
_ExtentX = 847
_ExtentY = 847
_Version = 393216
End
Begin MSComctlLib.ImageList ImageList1
Left = 5505
Top = 1140
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 32
ImageHeight = 32
MaskColor = 12632256
_Version = 393216
BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628}
NumListImages = 10
BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":08CA
Key = ""
EndProperty
BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":0DD2
Key = ""
EndProperty
BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":12E1
Key = ""
EndProperty
BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":183A
Key = ""
EndProperty
BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":1DE8
Key = ""
EndProperty
BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":2350
Key = ""
EndProperty
BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":28A0
Key = ""
EndProperty
BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":2E57
Key = ""
EndProperty
BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":3376
Key = ""
EndProperty
BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":3C50
Key = ""
EndProperty
EndProperty
End
Begin MSComctlLib.Toolbar Toolbar1
Align = 1 'Align Top
Height = 855
Left = 0
TabIndex = 0
Top = 0
Width = 14745
_ExtentX = 26009
_ExtentY = 1508
ButtonWidth = 1455
ButtonHeight = 1349
Appearance = 1
ImageList = "ImageList1"
_Version = 393216
BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628}
NumButtons = 5
BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "借书"
Key = "js"
ImageIndex = 1
EndProperty
BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "还书"
Key = "hs"
ImageIndex = 2
EndProperty
BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "查询借阅"
Key = "cxjy"
ImageIndex = 3
EndProperty
BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "帮助"
Key = "bz"
ImageIndex = 9
EndProperty
BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628}
Caption = "退出"
Key = "tc"
ImageIndex = 10
EndProperty
EndProperty
BorderStyle = 1
Enabled = 0 'False
End
Begin MSComctlLib.ImageList ImageList2
Left = 780
Top = 2055
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 16
ImageHeight = 16
_Version = 393216
BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628}
NumListImages = 11
BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":452A
Key = ""
EndProperty
BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":4A7C
Key = ""
EndProperty
BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":4FCE
Key = ""
EndProperty
BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":5520
Key = ""
EndProperty
BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":5A72
Key = ""
EndProperty
BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":5D8C
Key = ""
EndProperty
BeginProperty ListImage7 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":60A6
Key = ""
EndProperty
BeginProperty ListImage8 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":65F8
Key = ""
EndProperty
BeginProperty ListImage9 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":6912
Key = ""
EndProperty
BeginProperty ListImage10 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":6E64
Key = ""
EndProperty
BeginProperty ListImage11 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frm_main.frx":73B6
Key = ""
EndProperty
EndProperty
End
Begin MSComctlLib.StatusBar StatusBar1
Align = 2 'Align Bottom
Height = 420
Left = 0
TabIndex = 1
Top = 9000
Width = 14745
_ExtentX = 26009
_ExtentY = 741
_Version = 393216
BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628}
EndProperty
End
Begin VB.Menu jygl
Caption = "【借阅管理】"
WindowList = -1 'True
Begin VB.Menu js
Caption = "借书"
Shortcut = ^J
End
Begin VB.Menu hs
Caption = "还书"
Shortcut = ^H
End
Begin VB.Menu cxjy
Caption = "查询借阅"
Shortcut = ^X
End
End
Begin VB.Menu tsgl
Caption = "【图书管理】"
Begin VB.Menu sjlb
Caption = "书籍列表"
End
Begin VB.Menu x
Caption = "---------------"
End
Begin VB.Menu tjsj
Caption = "添加书籍"
End
Begin VB.Menu sjxg
Caption = "书籍修改"
End
Begin VB.Menu cxsj
Caption = "查询书籍"
End
Begin VB.Menu scsj
Caption = "删除书籍"
End
Begin VB.Menu x2
Caption = "---------------"
End
Begin VB.Menu tslbgl
Caption = "图书类别管理"
End
Begin VB.Menu cbsxxgl
Caption = "出版社信息管理"
End
End
Begin VB.Menu dzgl
Caption = "【读者管理】"
Begin VB.Menu tjjyz
Caption = "添加借阅者"
End
Begin VB.Menu scjyz
Caption = "删除借阅者"
End
Begin VB.Menu jyzlbgl
Caption = "借阅者类别管理"
End
End
Begin VB.Menu tsdggl
Caption = "【图书订购管理】"
Begin VB.Menu tsdg
Caption = "图书订购"
Shortcut = ^D
End
End
Begin VB.Menu xtgl
Caption = "【系统管理】"
Begin VB.Menu tjczy
Caption = "添加操作员"
End
Begin VB.Menu scczy
Caption = "删除操作员"
End
Begin VB.Menu xgmm
Caption = "修改密码"
End
Begin VB.Menu bz
Caption = "帮助"
Shortcut = {F1}
End
Begin VB.Menu about
Caption = "关于"
Shortcut = {F8}
End
Begin VB.Menu tc
Caption = "退出"
Shortcut = ^C
End
End
End
Attribute VB_Name = "frm_main"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'****************************************************************************
' 作者:林永刚
' 名称:frm_main
' 功能:主窗口。
'****************************************************************************
Private Declare Function GetMenu Lib "user32" (ByVal hwnd As Long) As Long
Private Declare Function GetSubMenu Lib "user32" (ByVal hMenu As Long, ByVal nPos As Long) As Long
Private Declare Function GetMenuItemID Lib "user32" (ByVal hMenu As Long, ByVal nPos As Long) As Long
Private Declare Function SetMenuItemBitmaps Lib "user32" (ByVal hMenu As Long, ByVal nPosition As Long, ByVal wFlags As Long, ByVal hBitmapUnchecked As Long, ByVal hBitmapChecked As Long) As Long
Const MF_bitmap = &H4&
Private Sub about_Click()
frmAbout.Show
End Sub
Private Sub cxjy_Click()
frmBorrowReturn.Show
End Sub
Private Sub cxsj_Click()
frmQueueBook.Show
End Sub
Private Sub Form_Load()
Dim i As Integer
Dim menu1 As Long
Dim menuID As Long
'添加面板
Dim pnlX As Panel
Set pnlX = StatusBar1.Panels.Add
pnlX.Text = "当前操作员: " & user
pnlX.Width = 2000
Set pnlX = StatusBar1.Panels.Add
pnlX.Style = sbrDate
pnlX.Width = 1500
Set pnlX = StatusBar1.Panels.Add
pnlX.Style = sbrTime
pnlX.Width = 1500
Set pnlX = StatusBar1.Panels.Add
pnlX.Text = "版权所有:林永刚 叶和平 叶茵茵"
pnlX.Width = 4000
Set pnlX = StatusBar1.Panels.Add
pnlX.Text = "图书管理系统 V1.0"
pnlX.Width = 6000
'根据不同权限,显示不同的操作
If limite = 1 Then '具有借阅管理
'jygl.Enabled =False
Toolbar1.Enabled = True
tsgl.Enabled = False
dzgl.Enabled = False
tsdggl.Enabled = False
scczy.Enabled = False
'xtgl.Enabled = False
tjczy.Enabled = False
tjjyz.Enabled = False
'js.Enabled = False
'hs.Enabled = False
ElseIf limite = 2 Then '具有分编管理
jygl.Enabled = False
scczy.Enabled = False
'tsgl.Enabled = False
dzgl.Enabled = False
tsdggl.Enabled = False
tjczy.Enabled = False
'xtgl.Enabled = False
tjjyz.Enabled = False
js.Enabled = False
hs.Enabled = False
ElseIf limite = 3 Then '具有图书采购
jygl.Enabled = False
scczy.Enabled = False
tsgl.Enabled = False
dzgl.Enabled = False
tjczy.Enabled = False
'tsdggl.Enabled = False
'xtgl.Enabled = False
tjjyz.Enabled = False
js.Enabled = False
hs.Enabled = False
ElseIf limite = 4 Then '具有办理借阅证
jygl.Enabled = False
tsgl.Enabled = False
scczy.Enabled = False
tjczy.Enabled = False
'dzgl.Enabled = False
tsdggl.Enabled = False
'xtgl.Enabled = False
'tjjyz.Enabled = False
js.Enabled = False
hs.Enabled = False
End If
' Stb1. = user
menu1 = GetMenu(Me.hwnd)
For i = 1 To 4
menuID = GetMenuItemID(GetSubMenu(menu1, 0), i - 1)
SetMenuItemBitmaps menu1, menuID, MF_bitmap, ImageList2.ListImages(i).Picture, ImageList2.ListImages(i).Picture
Next
End Sub
Private Sub sjgx_Click()
frmBooksInfo.Show
End Sub
Private Sub hs_Click()
frmBorrowReturn.Show
End Sub
Private Sub js_Click()
frmBorrowReturn.Show
End Sub
Private Sub jyzlbgl_Click()
frmBorrowLBmanage.Show
End Sub
Private Sub scczy_Click()
frmDelAdmin.Show
End Sub
Private Sub scjyz_Click()
frmDelReader.Show
End Sub
Private Sub scsj_Click()
frmBooksInfo.Show
End Sub
Private Sub sjlb_Click()
frmBooksInfo.Show
End Sub
Private Sub sjxg_Click()
frmBookModify.Show
End Sub
Private Sub tc_Click()
End
End Sub
Private Sub tjczy_Click()
frmAddAdmin.Show
End Sub
Private Sub tjjyz_Click()
frmAddReader.Show
End Sub
Private Sub tjsj_Click()
frmAddBook.Show
End Sub
Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button)
Select Case Button.Key
Case Is = "tc"
End
Case Is = "hs"
frmBorrowReturn.Show
Case Is = "js"
frmBorrowReturn.Show
Case Is = "tjjyz"
frmAddReader.Show
End Select
End Sub
Private Sub tsdg_Click()
frmBooksBuy.Show
End Sub
Private Sub xgmm_Click()
frmModifyPwd.Show
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -