📄 frmlist.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
Begin VB.Form frmList
Caption = "图书逾期清单"
ClientHeight = 3630
ClientLeft = 60
ClientTop = 345
ClientWidth = 9030
Icon = "frmList.frx":0000
LinkTopic = "Form1"
MDIChild = -1 'True
ScaleHeight = 3630
ScaleWidth = 9030
Begin VB.Frame Frame1
Height = 615
Left = 0
TabIndex = 1
Top = 0
Width = 9015
Begin VB.TextBox txbTwo
Height = 270
Left = 4320
TabIndex = 5
Top = 240
Width = 1215
End
Begin VB.CommandButton btnSearch
Caption = "搜索"
Height = 255
Left = 120
TabIndex = 4
Top = 240
Width = 615
End
Begin VB.TextBox txbOne
Height = 270
Left = 2040
TabIndex = 3
Top = 240
Width = 1215
End
Begin VB.TextBox txbThree
Height = 270
Left = 6600
TabIndex = 2
Top = 240
Width = 1215
End
Begin VB.Label Label1
Caption = "读者编号"
Height = 255
Left = 1200
TabIndex = 8
Top = 240
Width = 855
End
Begin VB.Label Label2
Caption = "读者条码"
Height = 255
Left = 3480
TabIndex = 7
Top = 240
Width = 855
End
Begin VB.Label Label3
Caption = "图书编号"
Height = 255
Left = 5760
TabIndex = 6
Top = 240
Width = 1095
End
End
Begin MSDataGridLib.DataGrid grdDataGrid
Bindings = "frmList.frx":0442
Height = 2895
Left = 0
TabIndex = 0
Top = 720
Width = 9015
_ExtentX = 15901
_ExtentY = 5106
_Version = 393216
HeadLines = 1
RowHeight = 15
FormatLocked = -1 'True
BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ColumnCount = 10
BeginProperty Column00
DataField = "借阅编号"
Caption = "借阅编号"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column01
DataField = "图书编号"
Caption = "图书编号"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column02
DataField = "图书名称"
Caption = "图书名称"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column03
DataField = "借阅时间"
Caption = "借阅时间"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column04
DataField = "应还时间"
Caption = "应还时间"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column05
DataField = "姓名"
Caption = "姓名"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column06
DataField = "读者编号"
Caption = "读者编号"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column07
DataField = "续借次数"
Caption = "续借次数"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column08
DataField = "操作员"
Caption = "操作员"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column09
DataField = "状态"
Caption = "状态"
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
SplitCount = 1
BeginProperty Split0
BeginProperty Column00
ColumnWidth = 810.142
EndProperty
BeginProperty Column01
ColumnWidth = 810.142
EndProperty
BeginProperty Column02
ColumnWidth = 2025.071
EndProperty
BeginProperty Column03
ColumnWidth = 810.142
EndProperty
BeginProperty Column04
ColumnWidth = 810.142
EndProperty
BeginProperty Column05
ColumnWidth = 524.976
EndProperty
BeginProperty Column06
ColumnWidth = 840.189
EndProperty
BeginProperty Column07
ColumnWidth = 824.882
EndProperty
BeginProperty Column08
ColumnWidth = 585.071
EndProperty
BeginProperty Column09
ColumnWidth = 480.189
EndProperty
EndProperty
End
Begin MSAdodcLib.Adodc Adodc1
Height = 330
Left = 360
Top = 3720
Visible = 0 'False
Width = 1200
_ExtentX = 2117
_ExtentY = 582
ConnectMode = 0
CursorLocation = 3
IsolationLevel = -1
ConnectionTimeout= 15
CommandTimeout = 30
CursorType = 3
LockType = 3
CommandType = 8
CursorOptions = 0
CacheSize = 50
MaxRecords = 0
BOFAction = 0
EOFAction = 0
ConnectStringType= 3
Appearance = 1
BackColor = -2147483643
ForeColor = -2147483640
Orientation = 0
Enabled = -1
Connect = "DSN=liblink"
OLEDBString = ""
OLEDBFile = ""
DataSourceName = "liblink"
OtherAttributes = ""
UserName = ""
Password = ""
RecordSource = $"frmList.frx":0457
Caption = "Adodc1"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
_Version = 393216
End
End
Attribute VB_Name = "frmList"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub LoadData()
Dim strFilter As String
If Len(Trim(txbOne.Text)) = 0 Then
If Len(Trim(txbTwo.Text)) = 0 Then
If Len(Trim(txbThree.Text)) = 0 Then
strFilter = ""
Else
strFilter = "and 图书编号 like '"
strFilter = strFilter + Trim(txbThree.Text) + "%'"
End If
Else
strFilter = "where 读者条码 like '"
strFilter = strFilter + Trim(txbTwo.Text) + "%'"
If Len(Trim(txbThree.Text)) <> 0 Then
strFilter = strFilter + " and 图书编号 like '"
strFilter = strFilter + Trim(txbThree.Text) + "%'"
End If
End If
Else
strFilter = "and 读者编号 like '"
strFilter = strFilter + Trim(txbOne.Text) + "%'"
If Len(Trim(txbTwo.Text)) <> 0 Then
strFilter = strFilter + " and 读者条码 like '"
strFilter = strFilter + Trim(txbTwo.Text) + "%'"
If Len(Trim(txbThree.Text)) <> 0 Then
strFilter = strFilter + " and 图书编号 like '"
strFilter = strFilter + Trim(txbThree.Text) + "%'"
End If
Else
If Len(Trim(txbThree.Text)) <> 0 Then
strFilter = strFilter + " and 图书编号 like '"
strFilter = strFilter + Trim(txbThree.Text) + "%'"
End If
End If
End If
Dim db As New DataBases
Dim rs As New Recordset
Dim strSQL As String
strSQL = "select 借阅编号,c.图书编号,书名 as 图书名称 ,"
strSQL = strSQL + "借阅时间,应还时间,姓名,c.读者编号,续借次数,"
strSQL = strSQL + "c.操作员,状态 from 图书信息 as a, 读者信息 as b,"
strSQL = strSQL + "图书借阅 as c where a.编号 = c.图书编号"
strSQL = strSQL + " and b.编号 = c.读者编号 "
strSQL = strSQL + strFilter + " and 应还时间 < '" + CStr(Date) + "' and 状态='未还'"
Set rs = db.RunSelectSQL(strSQL)
Set Adodc1.Recordset = rs
End Sub
Private Sub btnSearch_Click()
LoadData
End Sub
Private Sub Form_Load()
Dim db As New DataBases
Adodc1.ConnectionString = db.sConn
LoadData
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -