📄 main.vb
字号:
Me.list_dy.Name = "list_dy"
Me.list_dy.Size = New System.Drawing.Size(88, 20)
Me.list_dy.TabIndex = 1
'
'Label1
'
Me.Label1.Location = New System.Drawing.Point(8, 13)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(72, 24)
Me.Label1.TabIndex = 2
Me.Label1.Text = "查询方式:"
Me.Label1.TextAlign = System.Drawing.ContentAlignment.MiddleRight
'
'list_condition
'
Me.list_condition.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.list_condition.Items.AddRange(New Object() {"正序", "倒序"})
Me.list_condition.Location = New System.Drawing.Point(216, 13)
Me.list_condition.Name = "list_condition"
Me.list_condition.Size = New System.Drawing.Size(88, 20)
Me.list_condition.TabIndex = 2
'
'Label2
'
Me.Label2.Location = New System.Drawing.Point(168, 13)
Me.Label2.Name = "Label2"
Me.Label2.Size = New System.Drawing.Size(48, 24)
Me.Label2.TabIndex = 4
Me.Label2.Text = "条件:"
Me.Label2.TextAlign = System.Drawing.ContentAlignment.MiddleRight
'
'Timer1
'
Me.Timer1.Interval = 6000
'
'MainWinMenu
'
Me.MainWinMenu.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_system, Me.Menu_condition, Me.Menu_boardctr, Me.Menu_bookinformation, Me.Menu_landinformation, Me.Menu_indinformation, Me.Menu_help})
'
'Menu_system
'
Me.Menu_system.Index = 0
Me.Menu_system.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.MenuItem5, Me.MenuItem6, Me.Menu_exit})
Me.Menu_system.Text = "系统(&F)"
'
'MenuItem5
'
Me.MenuItem5.Index = 0
Me.MenuItem5.Text = "最小化"
'
'MenuItem6
'
Me.MenuItem6.Index = 1
Me.MenuItem6.Text = "-"
'
'Menu_exit
'
Me.Menu_exit.Index = 2
Me.Menu_exit.Text = "退出(&X)"
'
'Menu_condition
'
Me.Menu_condition.Index = 1
Me.Menu_condition.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_bywhat, Me.Menu_bycondition})
Me.Menu_condition.Shortcut = System.Windows.Forms.Shortcut.CtrlC
Me.Menu_condition.Text = "查询条件(&C)"
'
'Menu_bywhat
'
Me.Menu_bywhat.Index = 0
Me.Menu_bywhat.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_byid, Me.Menu_bybookname, Me.Menu_byclassify, Me.Menu_byauthor, Me.Menu_byconcern, Me.Menu_byaddtime, Me.Menu_byamount, Me.Menu_byremain, Me.Menu_loandegree})
Me.Menu_bywhat.Shortcut = System.Windows.Forms.Shortcut.CtrlB
Me.Menu_bywhat.Text = "查询方式"
'
'Menu_byid
'
Me.Menu_byid.Index = 0
Me.Menu_byid.Text = "编号"
'
'Menu_bybookname
'
Me.Menu_bybookname.Index = 1
Me.Menu_bybookname.Text = "书名"
'
'Menu_byclassify
'
Me.Menu_byclassify.Index = 2
Me.Menu_byclassify.Text = "分类"
'
'Menu_byauthor
'
Me.Menu_byauthor.Index = 3
Me.Menu_byauthor.Text = "作者"
'
'Menu_byconcern
'
Me.Menu_byconcern.Index = 4
Me.Menu_byconcern.Text = "出版社"
'
'Menu_byaddtime
'
Me.Menu_byaddtime.Index = 5
Me.Menu_byaddtime.Text = "进馆时间"
'
'Menu_byamount
'
Me.Menu_byamount.Index = 6
Me.Menu_byamount.Text = "总数量"
'
'Menu_byremain
'
Me.Menu_byremain.Index = 7
Me.Menu_byremain.Text = "剩余数量"
'
'Menu_loandegree
'
Me.Menu_loandegree.Index = 8
Me.Menu_loandegree.Text = "借阅次数"
'
'Menu_bycondition
'
Me.Menu_bycondition.Index = 1
Me.Menu_bycondition.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_byjust, Me.Menu_byantitone})
Me.Menu_bycondition.Text = "条件"
'
'Menu_byjust
'
Me.Menu_byjust.Index = 0
Me.Menu_byjust.Text = "正序"
'
'Menu_byantitone
'
Me.Menu_byantitone.Index = 1
Me.Menu_byantitone.Text = "倒序"
'
'Menu_boardctr
'
Me.Menu_boardctr.Index = 2
Me.Menu_boardctr.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_stop})
Me.Menu_boardctr.Text = "公告控制(&A)"
'
'Menu_stop
'
Me.Menu_stop.Index = 0
Me.Menu_stop.Text = "停止"
'
'Menu_bookinformation
'
Me.Menu_bookinformation.Index = 3
Me.Menu_bookinformation.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_land})
Me.Menu_bookinformation.Text = "图书信息(&B)"
'
'Menu_land
'
Me.Menu_land.Index = 0
Me.Menu_land.Text = "借阅"
'
'Menu_landinformation
'
Me.Menu_landinformation.Index = 4
Me.Menu_landinformation.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.MenuItem1, Me.MenuItem2, Me.MenuItem3, Me.MenuItem4, Me.Menu_details})
Me.Menu_landinformation.Text = "借阅信息(&L)"
'
'MenuItem1
'
Me.MenuItem1.Index = 0
Me.MenuItem1.Text = "全部"
'
'MenuItem2
'
Me.MenuItem2.Index = 1
Me.MenuItem2.Text = "续借"
'
'MenuItem3
'
Me.MenuItem3.Index = 2
Me.MenuItem3.Text = "归还"
'
'MenuItem4
'
Me.MenuItem4.Index = 3
Me.MenuItem4.Text = "-"
'
'Menu_details
'
Me.Menu_details.Index = 4
Me.Menu_details.Text = "详细资料"
'
'Menu_indinformation
'
Me.Menu_indinformation.Index = 5
Me.Menu_indinformation.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_hideinformation, Me.Menu_changepw})
Me.Menu_indinformation.Text = "个人信息(&I)"
'
'Menu_hideinformation
'
Me.Menu_hideinformation.Index = 0
Me.Menu_hideinformation.Text = "隐藏信息"
'
'Menu_changepw
'
Me.Menu_changepw.Index = 1
Me.Menu_changepw.Text = "更改密码"
'
'Menu_help
'
Me.Menu_help.Index = 6
Me.Menu_help.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_about})
Me.Menu_help.Text = "帮助(&H)"
'
'Menu_about
'
Me.Menu_about.Index = 0
Me.Menu_about.Text = "关于"
'
'NotifyIcon1
'
Me.NotifyIcon1.ContextMenu = Me.ContextMenu1
Me.NotifyIcon1.Icon = CType(resources.GetObject("NotifyIcon1.Icon"), System.Drawing.Icon)
Me.NotifyIcon1.Text = "图书馆管理系统V1.0"
'
'ContextMenu1
'
Me.ContextMenu1.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.MenuItem8, Me.MenuItem7})
'
'MenuItem8
'
Me.MenuItem8.Index = 0
Me.MenuItem8.Text = "显示界面"
'
'MenuItem7
'
Me.MenuItem7.Index = 1
Me.MenuItem7.Text = "退出"
'
'win_main
'
Me.AutoScaleBaseSize = New System.Drawing.Size(6, 14)
Me.ClientSize = New System.Drawing.Size(1014, 697)
Me.Controls.Add(Me.GroupBox6)
Me.Controls.Add(Me.GroupBox5)
Me.Controls.Add(Me.GroupBox4)
Me.Controls.Add(Me.list_book)
Me.Controls.Add(Me.GroupBox3)
Me.Controls.Add(Me.StatusBar1)
Me.Controls.Add(Me.GroupBox2)
Me.Controls.Add(Me.GroupBox1)
Me.HelpButton = True
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
Me.Menu = Me.MainWinMenu
Me.Name = "win_main"
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "图书馆信息管理系统"
Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
Me.GroupBox6.ResumeLayout(False)
Me.GroupBox5.ResumeLayout(False)
Me.GroupBox4.ResumeLayout(False)
Me.GroupBox3.ResumeLayout(False)
Me.GroupBox2.ResumeLayout(False)
Me.GroupBox1.ResumeLayout(False)
Me.ResumeLayout(False)
End Sub
#End Region
Private Sub win_main_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
stuID = login.loginid '学生自动编号
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''读取图书馆基本配置
sqlstr = "SELECT * FROM libraryinfo"
Try
objDS = GetData(sqlstr)
canland = objDS.Tables(0).Rows(0)("canland").ToString
canlandnum = objDS.Tables(0).Rows(0)("canlandnum").ToString
canlanddays = objDS.Tables(0).Rows(0)("canlanddays").ToString
canreland = objDS.Tables(0).Rows(0)("canreland").ToString
boardflash = objDS.Tables(0).Rows(0)("boardreflash").ToString
Catch
MsgBox("图书馆基本配置错误。将恢复原始设置。", MsgBoxStyle.Information + MsgBoxStyle.OKOnly, "配置错误")
canland = 1
canlandnum = 5 '
canlanddays = 60
canreland = 5
boardflash = 6000
End Try
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''读取图书信息
sqlstr = "SELECT * FROM bookinfo where display=0 ORDER BY id"
Try
objDS = GetData(sqlstr)
For i = 0 To objDS.Tables(0).Rows.Count - 1
Call ShowData(i)
Next
Catch
MsgBox("图书读取错误。", MsgBoxStyle.Information + MsgBoxStyle.OKOnly, "错误")
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -