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

📄 frmlendreturn.frm

📁 图书管理系统
💻 FRM
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Begin VB.Form LendReturn 
   Caption         =   "图书借阅管理 "
   ClientHeight    =   4680
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   7440
   LinkTopic       =   "Form1"
   MDIChild        =   -1  'True
   ScaleHeight     =   4680
   ScaleWidth      =   7440
   Begin VB.CommandButton cmdExit 
      Caption         =   "关闭"
      Height          =   255
      Left            =   6360
      TabIndex        =   25
      Top             =   2640
      Width           =   735
   End
   Begin VB.CommandButton cmdClear 
      Caption         =   "清除"
      Height          =   255
      Left            =   5280
      TabIndex        =   24
      Top             =   2640
      Width           =   735
   End
   Begin VB.CommandButton cmdReturn 
      Caption         =   "还书"
      Enabled         =   0   'False
      Height          =   255
      Left            =   4200
      TabIndex        =   23
      Top             =   2640
      Width           =   735
   End
   Begin VB.CommandButton cmdReLend 
      Caption         =   "续借"
      Enabled         =   0   'False
      Height          =   255
      Left            =   3120
      TabIndex        =   22
      Top             =   2640
      Width           =   735
   End
   Begin VB.CommandButton cmdLend 
      Caption         =   "借书"
      Enabled         =   0   'False
      Height          =   255
      Left            =   2040
      TabIndex        =   21
      Top             =   2640
      Width           =   735
   End
   Begin VB.CommandButton cmdNum 
      Caption         =   "输入借阅证号"
      Enabled         =   0   'False
      Height          =   255
      Left            =   360
      TabIndex        =   20
      Top             =   2640
      Width           =   1455
   End
   Begin VB.ComboBox cmbRoom 
      DataMember      =   "LendReturn"
      DataSource      =   "Library_Manage"
      Height          =   300
      ItemData        =   "frmLendReturn.frx":0000
      Left            =   1200
      List            =   "frmLendReturn.frx":0019
      Style           =   2  'Dropdown List
      TabIndex        =   11
      Top             =   240
      Width           =   2055
   End
   Begin MSFlexGridLib.MSFlexGrid LendedBooks 
      Height          =   1215
      Left            =   360
      TabIndex        =   1
      Top             =   3120
      Width           =   6735
      _ExtentX        =   11880
      _ExtentY        =   2143
      _Version        =   393216
      Cols            =   8
   End
   Begin VB.Frame Frame1 
      Caption         =   "读者个人信息"
      Height          =   1935
      Left            =   360
      TabIndex        =   0
      Top             =   600
      Width           =   6735
      Begin VB.TextBox txtLended 
         Height          =   270
         Left            =   4440
         Locked          =   -1  'True
         TabIndex        =   19
         Top             =   1440
         Width           =   1935
      End
      Begin VB.TextBox txtLends 
         Height          =   270
         Left            =   4440
         Locked          =   -1  'True
         TabIndex        =   18
         Top             =   1080
         Width           =   1935
      End
      Begin VB.TextBox txtType 
         Height          =   270
         Left            =   4440
         Locked          =   -1  'True
         TabIndex        =   17
         Top             =   720
         Width           =   1935
      End
      Begin VB.TextBox txtDays 
         Height          =   270
         Left            =   4440
         Locked          =   -1  'True
         TabIndex        =   16
         Top             =   360
         Width           =   1935
      End
      Begin VB.TextBox txtDate 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         TabIndex        =   15
         Top             =   1440
         Width           =   1695
      End
      Begin VB.TextBox txtNum 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         TabIndex        =   14
         Top             =   1080
         Width           =   1695
      End
      Begin VB.TextBox txtDept 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         TabIndex        =   13
         Top             =   720
         Width           =   1695
      End
      Begin VB.TextBox txtName 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         TabIndex        =   12
         Top             =   360
         Width           =   1695
      End
      Begin VB.Label Label8 
         AutoSize        =   -1  'True
         Caption         =   "已借书数"
         Height          =   180
         Left            =   3480
         TabIndex        =   9
         Top             =   1440
         Width           =   720
      End
      Begin VB.Label Label7 
         AutoSize        =   -1  'True
         Caption         =   "可借书数"
         Height          =   180
         Left            =   3480
         TabIndex        =   8
         Top             =   1080
         Width           =   720
      End
      Begin VB.Label Label6 
         AutoSize        =   -1  'True
         Caption         =   "读者类别"
         Height          =   180
         Left            =   3480
         TabIndex        =   7
         Top             =   720
         Width           =   720
      End
      Begin VB.Label Label5 
         AutoSize        =   -1  'True
         Caption         =   "借书期限"
         Height          =   180
         Left            =   3480
         TabIndex        =   6
         Top             =   360
         Width           =   720
      End
      Begin VB.Label Label4 
         AutoSize        =   -1  'True
         Caption         =   "失效期"
         Height          =   180
         Left            =   240
         TabIndex        =   5
         Top             =   1440
         Width           =   540
      End
      Begin VB.Label Label3 
         AutoSize        =   -1  'True
         Caption         =   "证  号"
         Height          =   180
         Left            =   240
         TabIndex        =   4
         Top             =   1080
         Width           =   540
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         Caption         =   "部  门"
         Height          =   180
         Left            =   240
         TabIndex        =   3
         Top             =   720
         Width           =   540
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "姓  名"
         Height          =   180
         Left            =   240
         TabIndex        =   2
         Top             =   360
         Width           =   540
      End
   End
   Begin VB.Label Label9 
      AutoSize        =   -1  'True
      Caption         =   "库室名称"
      Height          =   180
      Left            =   360
      TabIndex        =   10
      Top             =   240
      Width           =   720
   End
End
Attribute VB_Name = "LendReturn"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim objBooks As Recordset, objInfo As Recordset
Private Sub cmbRoom_Click()
    cmdNum.Enabled = True
End Sub

'执行清除操作
Private Sub cmdClear_Click()
    Dim i%
    txtName = "": txtDept = "": txtNum = "": txtDate = ""
    txtDays = "": txtType = "": txtLends = "": txtLended = ""
    cmdNum.Enabled = True: cmdLend.Enabled = False
    cmdReLend.Enabled = False: cmdReturn.Enabled = False
    '清除借书清单
    With LendedBooks
        '删除2以上的行
        If .Rows > 2 Then
            For i = .Rows - 1 To 2 Step -1
                .RemoveItem i
            Next
        End If
        '清除第1行中的借书记录数据
        For i = 0 To .Cols - 1
            .TextMatrix(1, i) = ""
        Next
    End With
End Sub

Private Sub cmdReLend_Click()
    Dim iKN%, Index%, strSQL$
    If txtDays = "无限制" Or Val(txtLended) = 0 Then Exit Sub
    Index = Val((InputBox("请输入续借图书在借书清单中的序号:", _
                "图书借阅管理")))
    If Index < 1 Or Index > LendedBooks.Rows - 1 Then
        MsgBox "输入的序号无效!", vbCritical, "图书借阅管理"
        Exit Sub
    End If
    With LendedBooks
        '修改图书借阅记录
        strSQL = "UPDATE 图书借阅 SET 借期='" & Date & "',还期='" _

⌨️ 快捷键说明

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