⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 form2.frm

📁 实现图书信息管理
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Form2 
   AutoRedraw      =   -1  'True
   Caption         =   "图书借阅系统"
   ClientHeight    =   8370
   ClientLeft      =   165
   ClientTop       =   855
   ClientWidth     =   10845
   Icon            =   "Form2.frx":0000
   LinkTopic       =   "Form1"
   Picture         =   "Form2.frx":0442
   ScaleHeight     =   8370
   ScaleWidth      =   10845
   StartUpPosition =   3  '窗口缺省
   Begin VB.Label Label1 
      BackColor       =   &H80000005&
      BackStyle       =   0  'Transparent
      Caption         =   "欢迎使用图书借阅系统"
      BeginProperty Font 
         Name            =   "楷体_GB2312"
         Size            =   42
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H0000C0C0&
      Height          =   855
      Left            =   1320
      TabIndex        =   0
      Top             =   1080
      Width           =   8775
   End
   Begin VB.Menu mnu_D 
      Caption         =   "用户登陆"
      Begin VB.Menu mnu_user_add 
         Caption         =   "添加用户"
      End
      Begin VB.Menu mnu_restart 
         Caption         =   "重新登陆"
      End
      Begin VB.Menu mnu_exit 
         Caption         =   "退出"
      End
   End
   Begin VB.Menu mnu_reader 
      Caption         =   "读者信息管理"
      Begin VB.Menu mnu_r_add 
         Caption         =   "添加"
      End
      Begin VB.Menu mnu_r_alter 
         Caption         =   "修改"
      End
      Begin VB.Menu mnu_r_del 
         Caption         =   "删除"
      End
      Begin VB.Menu mnu_r_find 
         Caption         =   "查询"
      End
   End
   Begin VB.Menu mnu_book 
      Caption         =   "图书信息管理"
      Begin VB.Menu mnu_b_add 
         Caption         =   "添加"
      End
      Begin VB.Menu mnu_b_alter 
         Caption         =   "修改"
      End
      Begin VB.Menu mnu_b_del 
         Caption         =   "删除"
      End
      Begin VB.Menu mnu_b_find 
         Caption         =   "查询"
      End
   End
   Begin VB.Menu mnu_borrow 
      Caption         =   "借阅信息管理"
      Begin VB.Menu mnu_bw_borrow 
         Caption         =   "借书"
      End
      Begin VB.Menu mnu_bw_give 
         Caption         =   "还书"
      End
      Begin VB.Menu mnu_bw_find1 
         Caption         =   "当前借阅信息查询"
      End
      Begin VB.Menu mnu_bw_find2 
         Caption         =   "借阅历史查询"
      End
   End
End
Attribute VB_Name = "Form2"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

Private Sub Form_Unload(Cancel As Integer)
cnn.Close
End Sub

Private Sub mnu_b_add_Click()
Form6.Show
Form6.Command3.Enabled = False
End Sub

Private Sub mnu_b_alter_Click()
del = 2
Form4.Show 1
Form6.Command1.Enabled = False
Form6.Text1.Enabled = False
End Sub

Private Sub mnu_b_del_Click()
del = 2  '表示当前进行的操作是删除图书信息
Form5.Show
End Sub

Private Sub mnu_b_find_Click()
del = 2
Form4.Show 1
End Sub

Private Sub mnu_bw_borrow_Click()
bor = True  '表示当前进行的是借书操作
Set cmd.ActiveConnection = cnn

cmd.CommandText = "select ISBN from BOOK"
Set rs = cmd.Execute
If rs.EOF = True Then
    response = MsgBox("图书馆现在没有书", vbOKOnly + vbExclamation, "注意")
Else
    Frmborrow.Show
    Frmborrow.Combo3.Visible = False
    Frmborrow.Command2.Enabled = False
End If
End Sub

Private Sub mnu_bw_find1_Click()
Frminformation.DataGrid2.Visible = False
Frminformation.Show
End Sub

Private Sub mnu_bw_find2_Click()
Frminformation.DataGrid1.Visible = False
Frminformation.Show
End Sub

Private Sub mnu_bw_give_Click()
bor = False   '表示当前进行的是还书操作
Frmborrow.Show
Frmborrow.Command1.Enabled = False
Frmborrow.Text11.Visible = False
End Sub

Private Sub mnu_exit_Click()
cnn.Close
End
End Sub

Private Sub mnu_r_add_Click()
Form3.Show
Form3.Command3.Enabled = False
End Sub

Private Sub mnu_r_alter_Click()
del = 1
Form4.Show 1
Form3.Command1.Enabled = False
Form3.Text1.Enabled = False
End Sub

Private Sub mnu_r_del_Click()
del = 1  '表示当前进行的操作是删除读者信息
Form5.Show
End Sub

Private Sub mnu_r_find_Click()
del = 1
Form4.Show 1
End Sub

Private Sub mnu_restart_Click()
Unload Me
Frmmain.Show
End Sub

Private Sub mnu_user_add_Click()
updatepwd.Label1.Caption = "用户名:"
updatepwd.Label2.Caption = "密码:"
updatepwd.Command1.Caption = "添加"
updatepwd.Command2.Caption = "退出"
updatepwd.Caption = "添加用户"
updatepwd.Text1.PasswordChar = ""
updatepwd.Text2.PasswordChar = ""
updatepwd.Show
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -