Main.frm
上传用户:zhuahui520
上传日期:2007-05-21
资源大小:347k
文件大小:51k
源码类别:

其他智力游戏

开发平台:

Java

  1. VERSION 5.00
  2. Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
  3. Object = "{38911DA0-E448-11D0-84A3-00DD01104159}#1.1#0"; "COMCT332.OCX"
  4. Begin VB.Form Mainfrm 
  5.    Caption         =   "晗青图书管理系统"
  6.    ClientHeight    =   5535
  7.    ClientLeft      =   165
  8.    ClientTop       =   735
  9.    ClientWidth     =   8880
  10.    Icon            =   "Main.frx":0000
  11.    LinkTopic       =   "Form1"
  12.    ScaleHeight     =   5535
  13.    ScaleWidth      =   8880
  14.    StartUpPosition =   3  '窗口缺省
  15.    WindowState     =   2  'Maximized
  16.    Begin ComCtl3.CoolBar CoolBar1 
  17.       Height          =   690
  18.       Left            =   0
  19.       TabIndex        =   54
  20.       Top             =   0
  21.       Width           =   11895
  22.       _ExtentX        =   20981
  23.       _ExtentY        =   1217
  24.       BandCount       =   2
  25.       _CBWidth        =   11895
  26.       _CBHeight       =   690
  27.       _Version        =   "6.0.8169"
  28.       Child1          =   "Toolbar1"
  29.       MinHeight1      =   630
  30.       Width1          =   10770
  31.       NewRow1         =   0   'False
  32.       MinHeight2      =   360
  33.       NewRow2         =   0   'False
  34.       Begin MSComctlLib.Toolbar Toolbar1 
  35.          Height          =   630
  36.          Left            =   165
  37.          TabIndex        =   55
  38.          Top             =   30
  39.          Width           =   11475
  40.          _ExtentX        =   20241
  41.          _ExtentY        =   1111
  42.          ButtonWidth     =   2090
  43.          ButtonHeight    =   1005
  44.          TextAlignment   =   1
  45.          ImageList       =   "ImageList1"
  46.          _Version        =   393216
  47.          BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
  48.             NumButtons      =   6
  49.             BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  50.                Caption         =   "图书"
  51.                Object.ToolTipText     =   "添加编辑图书"
  52.                ImageIndex      =   1
  53.                Style           =   5
  54.                BeginProperty ButtonMenus {66833FEC-8583-11D1-B16A-00C0F0283628} 
  55.                   NumButtonMenus  =   2
  56.                   BeginProperty ButtonMenu1 {66833FEE-8583-11D1-B16A-00C0F0283628} 
  57.                      Key             =   "添加"
  58.                      Text            =   "添加新书(&T)"
  59.                   EndProperty
  60.                   BeginProperty ButtonMenu2 {66833FEE-8583-11D1-B16A-00C0F0283628} 
  61.                      Key             =   "编辑"
  62.                      Text            =   "编辑图书(&B)"
  63.                   EndProperty
  64.                EndProperty
  65.             EndProperty
  66.             BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  67.                Style           =   3
  68.             EndProperty
  69.             BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  70.                Caption         =   "借书证"
  71.                Object.ToolTipText     =   "添加编辑借书证"
  72.                ImageIndex      =   2
  73.             EndProperty
  74.             BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  75.                Style           =   3
  76.             EndProperty
  77.             BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  78.                Caption         =   "管理员"
  79.                Object.ToolTipText     =   "修改管理员"
  80.                ImageIndex      =   3
  81.             EndProperty
  82.             BeginProperty Button6 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  83.                Style           =   3
  84.             EndProperty
  85.          EndProperty
  86.       End
  87.    End
  88.    Begin MSComctlLib.StatusBar Sb 
  89.       Align           =   2  'Align Bottom
  90.       Height          =   375
  91.       Left            =   0
  92.       TabIndex        =   53
  93.       Top             =   5160
  94.       Width           =   8880
  95.       _ExtentX        =   15663
  96.       _ExtentY        =   661
  97.       _Version        =   393216
  98.       BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
  99.          NumPanels       =   4
  100.          BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  101.             Alignment       =   1
  102.             Object.Width           =   14111
  103.             MinWidth        =   14111
  104.             Text            =   "程序设计: 晗青软件工作室"
  105.             TextSave        =   "程序设计: 晗青软件工作室"
  106.          EndProperty
  107.          BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  108.             Style           =   1
  109.             Alignment       =   1
  110.             Enabled         =   0   'False
  111.             Object.Width           =   1764
  112.             MinWidth        =   1764
  113.             TextSave        =   "CAPS"
  114.          EndProperty
  115.          BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  116.             Style           =   5
  117.             TextSave        =   "13:00"
  118.          EndProperty
  119.          BeginProperty Panel4 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  120.             Style           =   6
  121.             TextSave        =   "2003-10-27"
  122.          EndProperty
  123.       EndProperty
  124.    End
  125.    Begin VB.Frame Frame7 
  126.       Caption         =   "快捷键"
  127.       Height          =   2775
  128.       Left            =   5160
  129.       TabIndex        =   38
  130.       Top             =   2160
  131.       Width           =   6615
  132.       Begin VB.Label Label3 
  133.          Caption         =   "ALT + H"
  134.          ForeColor       =   &H000000C0&
  135.          Height          =   180
  136.          Index           =   9
  137.          Left            =   3960
  138.          TabIndex        =   49
  139.          Top             =   840
  140.          Width           =   720
  141.       End
  142.       Begin VB.Label Label3 
  143.          AutoSize        =   -1  'True
  144.          Caption         =   "打开还书对话框"
  145.          ForeColor       =   &H00C000C0&
  146.          Height          =   180
  147.          Index           =   8
  148.          Left            =   1560
  149.          TabIndex        =   48
  150.          Top             =   840
  151.          Width           =   1260
  152.       End
  153.       Begin VB.Label Label3 
  154.          AutoSize        =   -1  'True
  155.          Caption         =   "ALT + C"
  156.          ForeColor       =   &H000000C0&
  157.          Height          =   180
  158.          Index           =   7
  159.          Left            =   3960
  160.          TabIndex        =   46
  161.          Top             =   2280
  162.          Width           =   630
  163.       End
  164.       Begin VB.Label Label3 
  165.          AutoSize        =   -1  'True
  166.          Caption         =   "ALT + S"
  167.          ForeColor       =   &H000000C0&
  168.          Height          =   180
  169.          Index           =   6
  170.          Left            =   3960
  171.          TabIndex        =   45
  172.          Top             =   1800
  173.          Width           =   630
  174.       End
  175.       Begin VB.Label Label3 
  176.          AutoSize        =   -1  'True
  177.          Caption         =   "ALT + K"
  178.          ForeColor       =   &H000000C0&
  179.          Height          =   180
  180.          Index           =   5
  181.          Left            =   3960
  182.          TabIndex        =   44
  183.          Top             =   1320
  184.          Width           =   630
  185.       End
  186.       Begin VB.Label Label3 
  187.          Caption         =   "ALT + D "
  188.          ForeColor       =   &H000000C0&
  189.          Height          =   180
  190.          Index           =   4
  191.          Left            =   3960
  192.          TabIndex        =   43
  193.          Top             =   360
  194.          Width           =   720
  195.       End
  196.       Begin VB.Label Label3 
  197.          AutoSize        =   -1  'True
  198.          Caption         =   "归还图书"
  199.          ForeColor       =   &H00C000C0&
  200.          Height          =   180
  201.          Index           =   3
  202.          Left            =   1560
  203.          TabIndex        =   42
  204.          Top             =   2280
  205.          Width           =   720
  206.       End
  207.       Begin VB.Label Label3 
  208.          AutoSize        =   -1  'True
  209.          Caption         =   "借出图书"
  210.          ForeColor       =   &H00C000C0&
  211.          Height          =   180
  212.          Index           =   2
  213.          Left            =   1560
  214.          TabIndex        =   41
  215.          Top             =   1800
  216.          Width           =   720
  217.       End
  218.       Begin VB.Label Label3 
  219.          AutoSize        =   -1  'True
  220.          Caption         =   "清空所有文本"
  221.          ForeColor       =   &H00C000C0&
  222.          Height          =   180
  223.          Index           =   1
  224.          Left            =   1560
  225.          TabIndex        =   40
  226.          Top             =   1320
  227.          Width           =   1080
  228.       End
  229.       Begin VB.Label Label3 
  230.          AutoSize        =   -1  'True
  231.          Caption         =   "打开登录对话框"
  232.          ForeColor       =   &H00C000C0&
  233.          Height          =   180
  234.          Index           =   0
  235.          Left            =   1560
  236.          TabIndex        =   39
  237.          Top             =   360
  238.          Width           =   1260
  239.       End
  240.       Begin VB.Image Image3 
  241.          Height          =   480
  242.          Left            =   600
  243.          Picture         =   "Main.frx":0442
  244.          Top             =   600
  245.          Width           =   480
  246.       End
  247.    End
  248.    Begin VB.Frame Frame6 
  249.       BackColor       =   &H8000000A&
  250.       BorderStyle     =   0  'None
  251.       BeginProperty Font 
  252.          Name            =   "隶书"
  253.          Size            =   12
  254.          Charset         =   134
  255.          Weight          =   400
  256.          Underline       =   0   'False
  257.          Italic          =   0   'False
  258.          Strikethrough   =   0   'False
  259.       EndProperty
  260.       ForeColor       =   &H000000FF&
  261.       Height          =   3855
  262.       Left            =   120
  263.       TabIndex        =   32
  264.       Top             =   840
  265.       Width           =   615
  266.       Begin VB.CommandButton cmdBackBook 
  267.          Caption         =   "还书(&H)"
  268.          Height          =   255
  269.          Left            =   -240
  270.          TabIndex        =   47
  271.          Top             =   4200
  272.          Width           =   255
  273.       End
  274.       Begin MSComctlLib.Toolbar Toolbar2 
  275.          Height          =   5385
  276.          Left            =   0
  277.          TabIndex        =   37
  278.          Top             =   0
  279.          Width           =   615
  280.          _ExtentX        =   1085
  281.          _ExtentY        =   9499
  282.          ButtonWidth     =   1032
  283.          ButtonHeight    =   1349
  284.          Appearance      =   1
  285.          Style           =   1
  286.          ImageList       =   "ImageList2"
  287.          _Version        =   393216
  288.          BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
  289.             NumButtons      =   7
  290.             BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  291.                Caption         =   "登录"
  292.                ImageIndex      =   1
  293.             EndProperty
  294.             BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  295.                Style           =   3
  296.             EndProperty
  297.             BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  298.                Caption         =   "清空"
  299.                ImageIndex      =   2
  300.             EndProperty
  301.             BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  302.                Style           =   3
  303.             EndProperty
  304.             BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  305.                Caption         =   "查找"
  306.                ImageIndex      =   3
  307.             EndProperty
  308.             BeginProperty Button6 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  309.                Style           =   3
  310.             EndProperty
  311.             BeginProperty Button7 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  312.                Caption         =   "还书"
  313.                ImageIndex      =   4
  314.             EndProperty
  315.          EndProperty
  316.          BorderStyle     =   1
  317.       End
  318.       Begin VB.CommandButton cmdKong 
  319.          BackColor       =   &H000080FF&
  320.          Caption         =   "清空(&K)"
  321.          BeginProperty Font 
  322.             Name            =   "楷体_GB2312"
  323.             Size            =   15
  324.             Charset         =   134
  325.             Weight          =   700
  326.             Underline       =   0   'False
  327.             Italic          =   0   'False
  328.             Strikethrough   =   0   'False
  329.          EndProperty
  330.          Height          =   300
  331.          Left            =   0
  332.          Style           =   1  'Graphical
  333.          TabIndex        =   33
  334.          Top             =   3360
  335.          Width           =   615
  336.       End
  337.       Begin VB.CommandButton CmdLogin 
  338.          BackColor       =   &H000080FF&
  339.          Caption         =   "登录(&D)"
  340.          BeginProperty Font 
  341.             Name            =   "楷体_GB2312"
  342.             Size            =   15
  343.             Charset         =   134
  344.             Weight          =   700
  345.             Underline       =   0   'False
  346.             Italic          =   0   'False
  347.             Strikethrough   =   0   'False
  348.          EndProperty
  349.          Height          =   375
  350.          Left            =   0
  351.          Style           =   1  'Graphical
  352.          TabIndex        =   0
  353.          Top             =   3720
  354.          Width           =   615
  355.       End
  356.    End
  357.    Begin VB.Frame Frame3 
  358.       Caption         =   "借书"
  359.       BeginProperty Font 
  360.          Name            =   "楷体_GB2312"
  361.          Size            =   14.25
  362.          Charset         =   134
  363.          Weight          =   700
  364.          Underline       =   0   'False
  365.          Italic          =   0   'False
  366.          Strikethrough   =   0   'False
  367.       EndProperty
  368.       ForeColor       =   &H00FF0000&
  369.       Height          =   4215
  370.       Left            =   4920
  371.       TabIndex        =   14
  372.       Top             =   720
  373.       Width           =   6975
  374.       Begin MSComctlLib.ImageList ImageList2 
  375.          Left            =   4800
  376.          Top             =   2040
  377.          _ExtentX        =   1005
  378.          _ExtentY        =   1005
  379.          BackColor       =   -2147483643
  380.          ImageWidth      =   32
  381.          ImageHeight     =   32
  382.          MaskColor       =   12632256
  383.          _Version        =   393216
  384.          BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  385.             NumListImages   =   4
  386.             BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  387.                Picture         =   "Main.frx":0884
  388.                Key             =   ""
  389.             EndProperty
  390.             BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  391.                Picture         =   "Main.frx":0CD8
  392.                Key             =   ""
  393.             EndProperty
  394.             BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  395.                Picture         =   "Main.frx":112C
  396.                Key             =   ""
  397.             EndProperty
  398.             BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  399.                Picture         =   "Main.frx":1580
  400.                Key             =   ""
  401.             EndProperty
  402.          EndProperty
  403.       End
  404.       Begin VB.Frame Frame4 
  405.          Height          =   2775
  406.          Left            =   240
  407.          TabIndex        =   16
  408.          Top             =   1440
  409.          Visible         =   0   'False
  410.          Width           =   6615
  411.          Begin VB.CommandButton cmdOkCancel 
  412.             BackColor       =   &H000080FF&
  413.             Caption         =   "借出图书(&S)"
  414.             BeginProperty Font 
  415.                Name            =   "楷体_GB2312"
  416.                Size            =   12
  417.                Charset         =   134
  418.                Weight          =   700
  419.                Underline       =   0   'False
  420.                Italic          =   0   'False
  421.                Strikethrough   =   0   'False
  422.             EndProperty
  423.             Height          =   495
  424.             Index           =   1
  425.             Left            =   4680
  426.             Style           =   1  'Graphical
  427.             TabIndex        =   36
  428.             Top             =   2040
  429.             Width           =   1695
  430.          End
  431.          Begin VB.TextBox txtType 
  432.             BeginProperty Font 
  433.                Name            =   "宋体"
  434.                Size            =   10.5
  435.                Charset         =   134
  436.                Weight          =   400
  437.                Underline       =   0   'False
  438.                Italic          =   0   'False
  439.                Strikethrough   =   0   'False
  440.             EndProperty
  441.             ForeColor       =   &H00FF0000&
  442.             Height          =   315
  443.             Left            =   5280
  444.             TabIndex        =   35
  445.             Text            =   "Text1"
  446.             Top             =   360
  447.             Width           =   1215
  448.          End
  449.          Begin VB.TextBox txtLentDate 
  450.             BeginProperty Font 
  451.                Name            =   "宋体"
  452.                Size            =   10.5
  453.                Charset         =   134
  454.                Weight          =   400
  455.                Underline       =   0   'False
  456.                Italic          =   0   'False
  457.                Strikethrough   =   0   'False
  458.             EndProperty
  459.             ForeColor       =   &H00FF0000&
  460.             Height          =   345
  461.             Left            =   1080
  462.             TabIndex        =   26
  463.             Text            =   "Text1"
  464.             Top             =   2160
  465.             Width           =   1455
  466.          End
  467.          Begin VB.TextBox txtChuBan 
  468.             BeginProperty Font 
  469.                Name            =   "宋体"
  470.                Size            =   10.5
  471.                Charset         =   134
  472.                Weight          =   400
  473.                Underline       =   0   'False
  474.                Italic          =   0   'False
  475.                Strikethrough   =   0   'False
  476.             EndProperty
  477.             ForeColor       =   &H00FF0000&
  478.             Height          =   300
  479.             Left            =   1080
  480.             TabIndex        =   24
  481.             Text            =   "Text1"
  482.             Top             =   1560
  483.             Width           =   3375
  484.          End
  485.          Begin VB.TextBox txtBookName 
  486.             BeginProperty Font 
  487.                Name            =   "宋体"
  488.                Size            =   10.5
  489.                Charset         =   134
  490.                Weight          =   400
  491.                Underline       =   0   'False
  492.                Italic          =   0   'False
  493.                Strikethrough   =   0   'False
  494.             EndProperty
  495.             ForeColor       =   &H00FF0000&
  496.             Height          =   330
  497.             Left            =   1080
  498.             TabIndex        =   23
  499.             Text            =   "Text1"
  500.             Top             =   960
  501.             Width           =   3375
  502.          End
  503.          Begin VB.TextBox txtCost 
  504.             BeginProperty Font 
  505.                Name            =   "宋体"
  506.                Size            =   10.5
  507.                Charset         =   134
  508.                Weight          =   400
  509.                Underline       =   0   'False
  510.                Italic          =   0   'False
  511.                Strikethrough   =   0   'False
  512.             EndProperty
  513.             ForeColor       =   &H00FF0000&
  514.             Height          =   315
  515.             Left            =   3360
  516.             TabIndex        =   22
  517.             Text            =   "Text1"
  518.             Top             =   360
  519.             Width           =   1095
  520.          End
  521.          Begin VB.TextBox txtBookHao 
  522.             BeginProperty Font 
  523.                Name            =   "宋体"
  524.                Size            =   10.5
  525.                Charset         =   134
  526.                Weight          =   400
  527.                Underline       =   0   'False
  528.                Italic          =   0   'False
  529.                Strikethrough   =   0   'False
  530.             EndProperty
  531.             ForeColor       =   &H00FF0000&
  532.             Height          =   315
  533.             Left            =   1080
  534.             TabIndex        =   21
  535.             Text            =   "Text1"
  536.             Top             =   360
  537.             Width           =   1455
  538.          End
  539.          Begin VB.Image Image1 
  540.             Height          =   480
  541.             Left            =   5160
  542.             Picture         =   "Main.frx":19D4
  543.             Top             =   1200
  544.             Width           =   480
  545.          End
  546.          Begin VB.Label Label2 
  547.             AutoSize        =   -1  'True
  548.             Caption         =   "类别"
  549.             BeginProperty Font 
  550.                Name            =   "宋体"
  551.                Size            =   10.5
  552.                Charset         =   134
  553.                Weight          =   400
  554.                Underline       =   0   'False
  555.                Italic          =   0   'False
  556.                Strikethrough   =   0   'False
  557.             EndProperty
  558.             ForeColor       =   &H00000000&
  559.             Height          =   210
  560.             Index           =   10
  561.             Left            =   4680
  562.             TabIndex        =   34
  563.             Top             =   480
  564.             Width           =   420
  565.          End
  566.          Begin VB.Label Label2 
  567.             AutoSize        =   -1  'True
  568.             Caption         =   "今天日期"
  569.             BeginProperty Font 
  570.                Name            =   "宋体"
  571.                Size            =   10.5
  572.                Charset         =   134
  573.                Weight          =   400
  574.                Underline       =   0   'False
  575.                Italic          =   0   'False
  576.                Strikethrough   =   0   'False
  577.             EndProperty
  578.             ForeColor       =   &H00000000&
  579.             Height          =   210
  580.             Index           =   8
  581.             Left            =   120
  582.             TabIndex        =   25
  583.             Top             =   2160
  584.             Width           =   840
  585.          End
  586.          Begin VB.Label Label2 
  587.             AutoSize        =   -1  'True
  588.             Caption         =   "出版社"
  589.             BeginProperty Font 
  590.                Name            =   "宋体"
  591.                Size            =   10.5
  592.                Charset         =   134
  593.                Weight          =   400
  594.                Underline       =   0   'False
  595.                Italic          =   0   'False
  596.                Strikethrough   =   0   'False
  597.             EndProperty
  598.             ForeColor       =   &H00000000&
  599.             Height          =   210
  600.             Index           =   7
  601.             Left            =   120
  602.             TabIndex        =   20
  603.             Top             =   1560
  604.             Width           =   630
  605.          End
  606.          Begin VB.Label Label2 
  607.             AutoSize        =   -1  'True
  608.             Caption         =   "价格"
  609.             BeginProperty Font 
  610.                Name            =   "宋体"
  611.                Size            =   10.5
  612.                Charset         =   134
  613.                Weight          =   400
  614.                Underline       =   0   'False
  615.                Italic          =   0   'False
  616.                Strikethrough   =   0   'False
  617.             EndProperty
  618.             ForeColor       =   &H00000000&
  619.             Height          =   210
  620.             Index           =   6
  621.             Left            =   2760
  622.             TabIndex        =   19
  623.             Top             =   480
  624.             Width           =   420
  625.          End
  626.          Begin VB.Label Label2 
  627.             AutoSize        =   -1  'True
  628.             Caption         =   "书    名"
  629.             BeginProperty Font 
  630.                Name            =   "宋体"
  631.                Size            =   10.5
  632.                Charset         =   134
  633.                Weight          =   400
  634.                Underline       =   0   'False
  635.                Italic          =   0   'False
  636.                Strikethrough   =   0   'False
  637.             EndProperty
  638.             ForeColor       =   &H00000000&
  639.             Height          =   210
  640.             Index           =   5
  641.             Left            =   120
  642.             TabIndex        =   18
  643.             Top             =   1080
  644.             Width           =   840
  645.          End
  646.          Begin VB.Label Label2 
  647.             AutoSize        =   -1  'True
  648.             Caption         =   "图书编号"
  649.             BeginProperty Font 
  650.                Name            =   "宋体"
  651.                Size            =   10.5
  652.                Charset         =   134
  653.                Weight          =   400
  654.                Underline       =   0   'False
  655.                Italic          =   0   'False
  656.                Strikethrough   =   0   'False
  657.             EndProperty
  658.             ForeColor       =   &H00000000&
  659.             Height          =   210
  660.             Index           =   4
  661.             Left            =   120
  662.             TabIndex        =   17
  663.             Top             =   480
  664.             Width           =   840
  665.          End
  666.       End
  667.       Begin VB.TextBox txtBookBian 
  668.          BeginProperty Font 
  669.             Name            =   "宋体"
  670.             Size            =   12
  671.             Charset         =   134
  672.             Weight          =   700
  673.             Underline       =   0   'False
  674.             Italic          =   0   'False
  675.             Strikethrough   =   0   'False
  676.          EndProperty
  677.          ForeColor       =   &H00FF0000&
  678.          Height          =   360
  679.          Left            =   2520
  680.          TabIndex        =   2
  681.          Top             =   540
  682.          Width           =   2175
  683.       End
  684.       Begin VB.Label Label4 
  685.          AutoSize        =   -1  'True
  686.          Caption         =   "**<才能借出图书>"
  687.          ForeColor       =   &H00FF0000&
  688.          Height          =   180
  689.          Index           =   1
  690.          Left            =   4920
  691.          TabIndex        =   28
  692.          Top             =   840
  693.          Width           =   1440
  694.       End
  695.       Begin VB.Label Label4 
  696.          AutoSize        =   -1  'True
  697.          Caption         =   "**<输入图书编号后回车>"
  698.          ForeColor       =   &H00FF0000&
  699.          Height          =   180
  700.          Index           =   0
  701.          Left            =   4920
  702.          TabIndex        =   27
  703.          Top             =   600
  704.          Width           =   1980
  705.       End
  706.       Begin VB.Label Label5 
  707.          AutoSize        =   -1  'True
  708.          Caption         =   "输入要借的图书编号"
  709.          BeginProperty Font 
  710.             Name            =   "宋体"
  711.             Size            =   12
  712.             Charset         =   134
  713.             Weight          =   700
  714.             Underline       =   0   'False
  715.             Italic          =   0   'False
  716.             Strikethrough   =   0   'False
  717.          EndProperty
  718.          ForeColor       =   &H000000C0&
  719.          Height          =   240
  720.          Index           =   0
  721.          Left            =   120
  722.          TabIndex        =   15
  723.          Top             =   600
  724.          Width           =   2310
  725.       End
  726.       Begin VB.Line Line2 
  727.          BorderColor     =   &H8000000D&
  728.          Index           =   0
  729.          X1              =   0
  730.          X2              =   6960
  731.          Y1              =   1200
  732.          Y2              =   1200
  733.       End
  734.    End
  735.    Begin VB.Frame Frame2 
  736.       Caption         =   "已借图书"
  737.       BeginProperty Font 
  738.          Name            =   "楷体_GB2312"
  739.          Size            =   12
  740.          Charset         =   134
  741.          Weight          =   700
  742.          Underline       =   0   'False
  743.          Italic          =   0   'False
  744.          Strikethrough   =   0   'False
  745.       EndProperty
  746.       ForeColor       =   &H00FF0000&
  747.       Height          =   2535
  748.       Left            =   120
  749.       TabIndex        =   4
  750.       Top             =   5040
  751.       Width           =   11775
  752.       Begin MSComctlLib.ListView LV2 
  753.          Height          =   1815
  754.          Left            =   120
  755.          TabIndex        =   5
  756.          Top             =   600
  757.          Width           =   11535
  758.          _ExtentX        =   20346
  759.          _ExtentY        =   3201
  760.          Sorted          =   -1  'True
  761.          LabelWrap       =   -1  'True
  762.          HideSelection   =   -1  'True
  763.          _Version        =   393217
  764.          ForeColor       =   65535
  765.          BackColor       =   8421376
  766.          BorderStyle     =   1
  767.          Appearance      =   1
  768.          BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  769.             Name            =   "宋体"
  770.             Size            =   10.5
  771.             Charset         =   134
  772.             Weight          =   400
  773.             Underline       =   0   'False
  774.             Italic          =   0   'False
  775.             Strikethrough   =   0   'False
  776.          EndProperty
  777.          NumItems        =   0
  778.       End
  779.       Begin VB.Label Label1 
  780.          AutoSize        =   -1  'True
  781.          Caption         =   "已经借的图书"
  782.          BeginProperty Font 
  783.             Name            =   "宋体"
  784.             Size            =   10.5
  785.             Charset         =   134
  786.             Weight          =   700
  787.             Underline       =   0   'False
  788.             Italic          =   0   'False
  789.             Strikethrough   =   0   'False
  790.          EndProperty
  791.          ForeColor       =   &H000000C0&
  792.          Height          =   210
  793.          Left            =   4800
  794.          TabIndex        =   6
  795.          Top             =   240
  796.          Width           =   1365
  797.       End
  798.    End
  799.    Begin VB.Frame Frame1 
  800.       Caption         =   "基本信息"
  801.       BeginProperty Font 
  802.          Name            =   "楷体_GB2312"
  803.          Size            =   12
  804.          Charset         =   134
  805.          Weight          =   700
  806.          Underline       =   0   'False
  807.          Italic          =   0   'False
  808.          Strikethrough   =   0   'False
  809.       EndProperty
  810.       ForeColor       =   &H00FF0000&
  811.       Height          =   4215
  812.       Left            =   840
  813.       TabIndex        =   3
  814.       Top             =   720
  815.       Width           =   4095
  816.       Begin VB.TextBox txtFa 
  817.          BeginProperty Font 
  818.             Name            =   "宋体"
  819.             Size            =   10.5
  820.             Charset         =   134
  821.             Weight          =   400
  822.             Underline       =   0   'False
  823.             Italic          =   0   'False
  824.             Strikethrough   =   0   'False
  825.          EndProperty
  826.          ForeColor       =   &H000000FF&
  827.          Height          =   345
  828.          Left            =   1200
  829.          TabIndex        =   51
  830.          Text            =   "Text1"
  831.          Top             =   3645
  832.          Width           =   1335
  833.       End
  834.       Begin VB.Frame Frame5 
  835.          Caption         =   "Frame5"
  836.          Height          =   135
  837.          Left            =   3720
  838.          TabIndex        =   31
  839.          Top             =   0
  840.          Width           =   15
  841.       End
  842.       Begin VB.TextBox txtZhiCheng 
  843.          BeginProperty Font 
  844.             Name            =   "宋体"
  845.             Size            =   10.5
  846.             Charset         =   134
  847.             Weight          =   400
  848.             Underline       =   0   'False
  849.             Italic          =   0   'False
  850.             Strikethrough   =   0   'False
  851.          EndProperty
  852.          ForeColor       =   &H00FF0000&
  853.          Height          =   330
  854.          Left            =   1200
  855.          TabIndex        =   30
  856.          Text            =   "Text1"
  857.          Top             =   3000
  858.          Width           =   1695
  859.       End
  860.       Begin MSComctlLib.ImageList ImageList1 
  861.          Left            =   5400
  862.          Top             =   4200
  863.          _ExtentX        =   1005
  864.          _ExtentY        =   1005
  865.          BackColor       =   -2147483643
  866.          ImageWidth      =   32
  867.          ImageHeight     =   32
  868.          MaskColor       =   12632256
  869.          _Version        =   393216
  870.          BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  871.             NumListImages   =   3
  872.             BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  873.                Picture         =   "Main.frx":1E16
  874.                Key             =   ""
  875.             EndProperty
  876.             BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  877.                Picture         =   "Main.frx":226A
  878.                Key             =   ""
  879.             EndProperty
  880.             BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  881.                Picture         =   "Main.frx":26BE
  882.                Key             =   ""
  883.             EndProperty
  884.          EndProperty
  885.       End
  886.       Begin VB.TextBox txtDepart 
  887.          BeginProperty Font 
  888.             Name            =   "宋体"
  889.             Size            =   10.5
  890.             Charset         =   134
  891.             Weight          =   400
  892.             Underline       =   0   'False
  893.             Italic          =   0   'False
  894.             Strikethrough   =   0   'False
  895.          EndProperty
  896.          ForeColor       =   &H00FF0000&
  897.          Height          =   345
  898.          Left            =   1200
  899.          TabIndex        =   13
  900.          Text            =   "Text1"
  901.          Top             =   2400
  902.          Width           =   1695
  903.       End
  904.       Begin VB.TextBox txtClass 
  905.          BeginProperty Font 
  906.             Name            =   "宋体"
  907.             Size            =   10.5
  908.             Charset         =   134
  909.             Weight          =   400
  910.             Underline       =   0   'False
  911.             Italic          =   0   'False
  912.             Strikethrough   =   0   'False
  913.          EndProperty
  914.          ForeColor       =   &H00FF0000&
  915.          Height          =   345
  916.          Left            =   1200
  917.          TabIndex        =   12
  918.          Text            =   "Text1"
  919.          Top             =   1800
  920.          Width           =   1695
  921.       End
  922.       Begin VB.TextBox txtName 
  923.          BeginProperty Font 
  924.             Name            =   "宋体"
  925.             Size            =   10.5
  926.             Charset         =   134
  927.             Weight          =   400
  928.             Underline       =   0   'False
  929.             Italic          =   0   'False
  930.             Strikethrough   =   0   'False
  931.          EndProperty
  932.          ForeColor       =   &H00FF0000&
  933.          Height          =   345
  934.          Left            =   1200
  935.          TabIndex        =   11
  936.          Text            =   "Text1"
  937.          Top             =   1200
  938.          Width           =   1695
  939.       End
  940.       Begin VB.TextBox txtBookId 
  941.          BeginProperty Font 
  942.             Name            =   "宋体"
  943.             Size            =   10.5
  944.             Charset         =   134
  945.             Weight          =   700
  946.             Underline       =   0   'False
  947.             Italic          =   0   'False
  948.             Strikethrough   =   0   'False
  949.          EndProperty
  950.          ForeColor       =   &H00FF0000&
  951.          Height          =   330
  952.          Left            =   1200
  953.          TabIndex        =   1
  954.          Text            =   "Text1"
  955.          Top             =   600
  956.          Width           =   1695
  957.       End
  958.       Begin VB.Label Label2 
  959.          AutoSize        =   -1  'True
  960.          Caption         =   "元"
  961.          BeginProperty Font 
  962.             Name            =   "宋体"
  963.             Size            =   10.5
  964.             Charset         =   134
  965.             Weight          =   400
  966.             Underline       =   0   'False
  967.             Italic          =   0   'False
  968.             Strikethrough   =   0   'False
  969.          EndProperty
  970.          ForeColor       =   &H00000000&
  971.          Height          =   210
  972.          Index           =   12
  973.          Left            =   2640
  974.          TabIndex        =   52
  975.          Top             =   3720
  976.          Width           =   210
  977.       End
  978.       Begin VB.Label Label2 
  979.          AutoSize        =   -1  'True
  980.          Caption         =   "共计欠费"
  981.          BeginProperty Font 
  982.             Name            =   "宋体"
  983.             Size            =   10.5
  984.             Charset         =   134
  985.             Weight          =   400
  986.             Underline       =   0   'False
  987.             Italic          =   0   'False
  988.             Strikethrough   =   0   'False
  989.          EndProperty
  990.          ForeColor       =   &H00000000&
  991.          Height          =   210
  992.          Index           =   11
  993.          Left            =   240
  994.          TabIndex        =   50
  995.          Top             =   3720
  996.          Width           =   840
  997.       End
  998.       Begin VB.Label Label2 
  999.          AutoSize        =   -1  'True
  1000.          Caption         =   "职   称"
  1001.          BeginProperty Font 
  1002.             Name            =   "宋体"
  1003.             Size            =   10.5
  1004.             Charset         =   134
  1005.             Weight          =   400
  1006.             Underline       =   0   'False
  1007.             Italic          =   0   'False
  1008.             Strikethrough   =   0   'False
  1009.          EndProperty
  1010.          ForeColor       =   &H00000000&
  1011.          Height          =   210
  1012.          Index           =   9
  1013.          Left            =   240
  1014.          TabIndex        =   29
  1015.          Top             =   3120
  1016.          Width           =   735
  1017.       End
  1018.       Begin VB.Image Image2 
  1019.          Height          =   480
  1020.          Left            =   3240
  1021.          Picture         =   "Main.frx":2B12
  1022.          Top             =   600
  1023.          Width           =   480
  1024.       End
  1025.       Begin VB.Label Label2 
  1026.          AutoSize        =   -1  'True
  1027.          Caption         =   "部   门"
  1028.          BeginProperty Font 
  1029.             Name            =   "宋体"
  1030.             Size            =   10.5
  1031.             Charset         =   134
  1032.             Weight          =   400
  1033.             Underline       =   0   'False
  1034.             Italic          =   0   'False
  1035.             Strikethrough   =   0   'False
  1036.          EndProperty
  1037.          ForeColor       =   &H00000000&
  1038.          Height          =   210
  1039.          Index           =   3
  1040.          Left            =   240
  1041.          TabIndex        =   10
  1042.          Top             =   2520
  1043.          Width           =   735
  1044.       End
  1045.       Begin VB.Label Label2 
  1046.          AutoSize        =   -1  'True
  1047.          Caption         =   "班   级"
  1048.          BeginProperty Font 
  1049.             Name            =   "宋体"
  1050.             Size            =   10.5
  1051.             Charset         =   134
  1052.             Weight          =   400
  1053.             Underline       =   0   'False
  1054.             Italic          =   0   'False
  1055.             Strikethrough   =   0   'False
  1056.          EndProperty
  1057.          ForeColor       =   &H00000000&
  1058.          Height          =   210
  1059.          Index           =   2
  1060.          Left            =   240
  1061.          TabIndex        =   9
  1062.          Top             =   1920
  1063.          Width           =   735
  1064.       End
  1065.       Begin VB.Label Label2 
  1066.          AutoSize        =   -1  'True
  1067.          Caption         =   "姓   名"
  1068.          BeginProperty Font 
  1069.             Name            =   "宋体"
  1070.             Size            =   10.5
  1071.             Charset         =   134
  1072.             Weight          =   400
  1073.             Underline       =   0   'False
  1074.             Italic          =   0   'False
  1075.             Strikethrough   =   0   'False
  1076.          EndProperty
  1077.          ForeColor       =   &H00000000&
  1078.          Height          =   210
  1079.          Index           =   1
  1080.          Left            =   240
  1081.          TabIndex        =   8
  1082.          Top             =   1320
  1083.          Width           =   735
  1084.       End
  1085.       Begin VB.Label Label2 
  1086.          AutoSize        =   -1  'True
  1087.          Caption         =   "借书证号"
  1088.          BeginProperty Font 
  1089.             Name            =   "宋体"
  1090.             Size            =   10.5
  1091.             Charset         =   134
  1092.             Weight          =   400
  1093.             Underline       =   0   'False
  1094.             Italic          =   0   'False
  1095.             Strikethrough   =   0   'False
  1096.          EndProperty
  1097.          ForeColor       =   &H00000000&
  1098.          Height          =   210
  1099.          Index           =   0
  1100.          Left            =   240
  1101.          TabIndex        =   7
  1102.          Top             =   720
  1103.          Width           =   840
  1104.       End
  1105.    End
  1106.    Begin VB.Line Line3 
  1107.       BorderColor     =   &H80000016&
  1108.       BorderStyle     =   6  'Inside Solid
  1109.       X1              =   2880
  1110.       X2              =   13920
  1111.       Y1              =   600
  1112.       Y2              =   600
  1113.    End
  1114.    Begin VB.Menu MnuFile 
  1115.       Caption         =   "控制(&C)"
  1116.       Begin VB.Menu FenMnu 
  1117.          Caption         =   "图书分类(&F)"
  1118.          Shortcut        =   ^F
  1119.       End
  1120.       Begin VB.Menu s5 
  1121.          Caption         =   "-"
  1122.       End
  1123.       Begin VB.Menu AddMnu 
  1124.          Caption         =   "添加新书(&A)"
  1125.          Shortcut        =   ^A
  1126.       End
  1127.       Begin VB.Menu EditMnu 
  1128.          Caption         =   "编辑图书(&E)"
  1129.          Shortcut        =   ^E
  1130.       End
  1131.       Begin VB.Menu s1 
  1132.          Caption         =   "-"
  1133.       End
  1134.       Begin VB.Menu EditIdMnu 
  1135.          Caption         =   "编辑借书证(&J)"
  1136.          Shortcut        =   ^J
  1137.       End
  1138.       Begin VB.Menu s2 
  1139.          Caption         =   "-"
  1140.       End
  1141.       Begin VB.Menu ExitMnu 
  1142.          Caption         =   "退出(&X)"
  1143.       End
  1144.    End
  1145.    Begin VB.Menu ToolMnu 
  1146.       Caption         =   "工具(&T)"
  1147.       Begin VB.Menu LoginMnu 
  1148.          Caption         =   "登录(&D)"
  1149.       End
  1150.       Begin VB.Menu SearchMnu 
  1151.          Caption         =   "查找(&F)"
  1152.       End
  1153.       Begin VB.Menu BackMnu 
  1154.          Caption         =   "还书(&H)"
  1155.       End
  1156.       Begin VB.Menu s3 
  1157.          Caption         =   "-"
  1158.       End
  1159.       Begin VB.Menu SetMnu 
  1160.          Caption         =   "设置(&S)"
  1161.          Shortcut        =   ^S
  1162.       End
  1163.    End
  1164.    Begin VB.Menu HelpMnu 
  1165.       Caption         =   "帮助(&H)"
  1166.       Begin VB.Menu AboutMnu 
  1167.          Caption         =   "关于本软件(&A)"
  1168.       End
  1169.    End
  1170. End
  1171. Attribute VB_Name = "Mainfrm"
  1172. Attribute VB_GlobalNameSpace = False
  1173. Attribute VB_Creatable = False
  1174. Attribute VB_PredeclaredId = True
  1175. Attribute VB_Exposed = False
  1176. Dim db1 As Database
  1177. Dim db2 As Database
  1178. Dim db3 As Database
  1179. Dim rst As Recordset
  1180. Dim rst1 As Recordset '打开表Personal
  1181. Dim rst2 As Recordset '打开表BookFlag
  1182. Dim rst3 As Recordset '打开表Book
  1183. Dim ws1 As Workspace
  1184. Dim ws2 As Workspace
  1185. Dim qry2 As QueryDef
  1186. Dim RecNumBookFf As Integer '表BookFf的记录个数
  1187. Dim SFlag As String
  1188. Private Type MSet
  1189.     BookNum As Integer
  1190.     BookCost As Single
  1191. End Type
  1192. Dim SetFlag As MSet
  1193. Option Explicit
  1194. Private Sub AboutMnu_Click()
  1195. Aboutfrm.Show (1)
  1196. End Sub
  1197. Private Sub AddMnu_Click()
  1198. Sb.Panels(1).Text = "添加新书"
  1199.         AddNewBook.Show (1)
  1200.         Sb.Panels(1).Text = SFlag
  1201. End Sub
  1202. Private Sub BackMnu_Click()
  1203. cmdBackBook_Click
  1204. End Sub
  1205. Private Sub cmdBackBook_Click() '打开还书对话框
  1206. cmdKong_Click
  1207. Lentfrm.Show (1)
  1208. cmdKong_Click
  1209. End Sub
  1210. Private Sub cmdKong_Click() '清空所有文本
  1211. txtBookId.Text = ""
  1212. txtName.Text = ""
  1213. txtClass.Text = ""
  1214. txtDepart.Text = ""
  1215. txtBookHao.Text = ""
  1216. txtBookName = ""
  1217. txtZhiCheng = ""
  1218. txtFa.Text = ""
  1219. txtBookBian.Text = ""
  1220. Frame4.Visible = False
  1221. Frame7.Visible = True
  1222. LV2.ListItems.Clear
  1223. CmdLogin.SetFocus
  1224. End Sub
  1225. Private Sub cmdOkCancel_Click(Index As Integer)
  1226. Select Case Index
  1227.     Case 1
  1228.         If rst3.Fields("是否借出") = True Then
  1229.             MsgBox "此书已经借出!", 0 + 48, "提示"
  1230.             txtBookBian.Text = ""
  1231.             txtBookBian.SetFocus
  1232.             Frame4.Visible = False
  1233.             Frame7.Visible = True
  1234.             Exit Sub
  1235.         End If
  1236.         rst2.AddNew
  1237.         rst2.Fields("图书编号") = rst3.Fields("图书编号")
  1238.         rst2.Fields("书名") = rst3.Fields("书名")
  1239.         rst2.Fields("价格") = rst3.Fields("价格")
  1240.         rst2.Fields("出版社") = rst3.Fields("出版社")
  1241.         rst2.Fields("借出日期") = Date
  1242.         rst2.Fields("借书证号") = BookId
  1243.         rst2.Fields("姓名") = txtName.Text
  1244.         rst2.Fields("类别") = rst3.Fields("类别")
  1245.         rst2.Update
  1246.         rst3.Edit
  1247.         rst3.Fields("是否借出") = True
  1248.         rst3.Fields("借出日期") = Date
  1249.         rst3.Update
  1250.         DataRef
  1251.         txtBookBian.Text = ""
  1252.         txtBookBian.SetFocus
  1253.         'CmdLogin.SetFocus
  1254.         Frame4.Visible = False
  1255.         Frame7.Visible = True
  1256. End Select
  1257. End Sub
  1258. Private Sub CmdLogin_Click()
  1259. loop1:  '如果没有此证,返回
  1260. LentLogin.Show (1)
  1261. If LoginFlag Then
  1262. LV2.ListItems.Clear
  1263. rst1.Seek "=", BookId  '查找借书证号码
  1264. If rst1.NoMatch Then
  1265.     MsgBox "没有此借书证号码!", 0 + 48, "错误"
  1266.     LoginFlag = False
  1267.     GoTo loop1  '返回loop1
  1268. End If
  1269. txtBookId.Text = BookId
  1270. txtName.Text = rst1.Fields("姓名") & vbNullString
  1271. txtClass.Text = rst1.Fields("班级") & vbNullString
  1272. txtDepart.Text = rst1.Fields("部门") & vbNullString
  1273. txtZhiCheng = rst1.Fields("职称") & vbNullString
  1274. txtFa.Text = rst1.Fields("罚款") & Empty
  1275. txtBookBian.Text = ""
  1276. Frame4.Visible = False
  1277. Frame7.Visible = True
  1278. txtBookBian.SetFocus
  1279. DataRef '输出所借图书
  1280. LoginFlag = False
  1281. If rst1.Fields("罚款") > 0 Then
  1282.    If MsgBox(txtBookId & " " & txtName & " 共计欠费 " _
  1283.         & rst1.Fields("罚款") & "元 是否从数据库中删除?", 4 + 48, "欠费") _
  1284.             = vbYes Then
  1285.         '从数据库中删除欠费记录
  1286.         rst1.Edit
  1287.         rst1.Fields("罚款") = 0
  1288.         rst1.Update
  1289.         txtFa.Text = rst1.Fields("罚款") & Empty
  1290.     End If
  1291. Else            '把罚款复制为0
  1292.     rst1.Edit
  1293.     rst1.Fields("罚款") = 0
  1294.     rst1.Update
  1295. End If
  1296. End If
  1297. End Sub
  1298. Private Sub EditIdMnu_Click()
  1299. Sb.Panels(1).Text = "编辑借书证"
  1300.         EditBookId.Show (1)
  1301.         Sb.Panels(1).Text = "编辑借书证"
  1302. End Sub
  1303. Private Sub EditMnu_Click()
  1304.         Sb.Panels(1).Text = "编辑图书"
  1305.         EditBook.Show (1)
  1306.         Sb.Panels(1).Text = "编辑图书"
  1307. End Sub
  1308. Private Sub ExitMnu_Click()
  1309. Unload Me
  1310. End Sub
  1311. Private Sub FenMnu_Click()
  1312. SetType.Show (1)
  1313. End Sub
  1314. Private Sub Form_Load()
  1315. Set db1 = Workspaces(0).OpenDatabase("DataBaseData.mdb", False)
  1316. Set rst1 = db1.OpenRecordset("Personal", dbOpenTable)
  1317. rst1.Index = "借书证号"
  1318. Set db2 = Workspaces(0).OpenDatabase("DataBaseData.mdb", False)
  1319. Set rst2 = db2.OpenRecordset("BookFf", dbOpenTable)
  1320. Set qry2 = db2.CreateQueryDef("")
  1321. rst2.Index = "图书编号"
  1322. Set db3 = Workspaces(0).OpenDatabase("DataBaseData.mdb", False)
  1323. Set rst3 = db3.OpenRecordset("Book", dbOpenTable)
  1324. rst3.Index = "图书编号"
  1325. Open "DatabaseSet.Dat" For Random As #1 Len = Len(SetFlag)
  1326. Get #1, 1, SetFlag
  1327. BookNum = SetFlag.BookNum
  1328. FaCost = SetFlag.BookCost
  1329. LV2.View = lvwReport
  1330. LV2.ColumnHeaders.Add , , "借书证号"
  1331. LV2.ColumnHeaders.Add , , "借书人姓名"
  1332. LV2.ColumnHeaders.Add , , "图书编号"
  1333. LV2.ColumnHeaders.Add , , "书名"
  1334. LV2.ColumnHeaders.Add , , "价格"
  1335. LV2.ColumnHeaders.Add , , "类别"
  1336. LV2.ColumnHeaders.Add , , "出版社"
  1337. LV2.ColumnHeaders.Add , , "借出日期"
  1338. SFlag = "程序设计: 晗青软件工作室"
  1339. txtBookId.Text = ""
  1340. txtName.Text = ""
  1341. txtClass.Text = ""
  1342. txtDepart.Text = ""
  1343. txtBookHao.Text = ""
  1344. txtBookName = ""
  1345. txtZhiCheng = ""
  1346. txtFa.Text = ""
  1347. txtCost = ""
  1348. txtChuBan = ""
  1349. txtLentDate = ""
  1350. End Sub
  1351. Private Sub Form_Unload(Cancel As Integer)
  1352. rst1.Close
  1353. rst2.Close
  1354. rst3.Close
  1355. db1.Close
  1356. db2.Close
  1357. db3.Close
  1358. Close #1
  1359. End Sub
  1360. Private Sub LoginMnu_Click()
  1361.  CmdLogin_Click
  1362. End Sub
  1363. Private Sub SearchMnu_Click()
  1364.  Findfrm.Show
  1365. End Sub
  1366. Private Sub SetMnu_Click()
  1367. setfrm.Show (1)
  1368. End Sub
  1369. Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button)
  1370. Select Case Button.Index
  1371.     Case 3
  1372.         Sb.Panels(1).Text = "编辑借书证"
  1373.         EditBookId.Show (1)
  1374.         Sb.Panels(1).Text = "编辑借书证"
  1375.     Case 5
  1376.         SetPer.Show (1)
  1377. End Select
  1378. End Sub
  1379. Private Sub Toolbar1_ButtonMenuClick(ByVal buttonmenu As MSComctlLib.buttonmenu)
  1380. Select Case buttonmenu.Key
  1381.     Case "添加"
  1382.         Sb.Panels(1).Text = "添加新书"
  1383.         AddNewBook.Show (1)
  1384.         Sb.Panels(1).Text = SFlag
  1385.     Case "编辑"
  1386.         Sb.Panels(1).Text = "编辑图书"
  1387.         EditBook.Show (1)
  1388.         Sb.Panels(1).Text = "编辑图书"
  1389.     Case "新借"
  1390.         MsgBox "Add BookCard"
  1391.     Case "编借"
  1392.         MsgBox "Edit BookCard"
  1393. End Select
  1394. End Sub
  1395. Private Sub Toolbar2_ButtonClick(ByVal Button As MSComctlLib.Button)
  1396. Select Case Button.Index
  1397.     Case 1
  1398.         CmdLogin_Click
  1399.     Case 3
  1400.         cmdKong_Click
  1401.     Case 7
  1402.         cmdBackBook_Click
  1403.     Case 5
  1404.         Findfrm.Show
  1405. End Select
  1406. End Sub
  1407. Private Sub txtBookBian_KeyPress(KeyAscii As Integer)
  1408. If KeyAscii = 13 Then
  1409.     If txtBookId.Text = "" Then
  1410.         MsgBox "请先登录!", 0 + 48, "提示"
  1411.         CmdLogin.SetFocus
  1412.         txtBookBian.Text = ""
  1413.         Exit Sub
  1414.     End If
  1415.     rst3.Seek "=", txtBookBian.Text
  1416.     If rst3.NoMatch Then
  1417.         MsgBox "没有此图书编号,请重新填写", 0 + 48, "填写错误"
  1418.         txtBookBian.SetFocus
  1419.         Frame4.Visible = False
  1420.         Frame7.Visible = True
  1421.         Exit Sub
  1422.     End If
  1423.     Frame4.Visible = True
  1424.     Frame7.Visible = False
  1425.     txtBookHao.Text = txtBookBian.Text
  1426.     txtBookName.Text = rst3.Fields("书名") & vbNullString
  1427.     txtChuBan.Text = rst3.Fields("出版社") & vbNullString
  1428.     txtCost.Text = rst3.Fields("价格") & Empty
  1429.     txtLentDate = Date
  1430.     txtType.Text = rst3.Fields("类别") & vbNullString
  1431. End If
  1432. End Sub
  1433. Private Sub DataRef()
  1434. Dim i As Integer
  1435. Dim SeaStr As String
  1436. SeaStr = "select * from Bookff where 借书证号="
  1437. SeaStr = SeaStr & "'" & BookId & "'"
  1438. qry2.SQL = SeaStr
  1439. Set rst = qry2.OpenRecordset()
  1440. If rst.RecordCount = 0 Then
  1441.      Label1.Caption = "可以借" & BookNum & "本书"
  1442.      Exit Sub
  1443. End If
  1444. rst.MoveLast
  1445. RecNumBookFf = rst.RecordCount
  1446. rst.MoveFirst
  1447. LV2.ListItems.Clear
  1448. For i = 1 To RecNumBookFf
  1449.     LV2.ListItems.Add i, , rst.Fields("借书证号") & vbNullString
  1450.     With LV2.ListItems(i)
  1451.         .SubItems(1) = rst.Fields("姓名") & vbNullString
  1452.          .SubItems(2) = rst.Fields("图书编号") & vbNullString
  1453.         .SubItems(3) = rst.Fields("书名") & vbNullString
  1454.         .SubItems(4) = rst.Fields("价格") & Empty
  1455.         .SubItems(5) = rst.Fields("类别") & vbNullString
  1456.         .SubItems(6) = rst.Fields("出版社") & vbNullString
  1457.         .SubItems(7) = rst.Fields("借出日期") & vbNullString
  1458.     End With
  1459.     rst.MoveNext
  1460.     If rst.EOF Then Exit For
  1461. Next i
  1462. If RecNumBookFf = BookNum Then
  1463.     MsgBox "已经借了 " & BookNum & "本书,不能再借了,请登录其它借书证号", 0 + 48, "提示"
  1464.     txtBookId.Text = ""
  1465.     txtName.Text = ""
  1466.     txtClass.Text = ""
  1467.     txtDepart.Text = ""
  1468.     txtZhiCheng = ""
  1469.     txtFa.Text = ""
  1470.     CmdLogin.SetFocus
  1471.     LV2.ListItems.Clear
  1472.     Label1.Caption = "已经借的书"
  1473.     Exit Sub
  1474. End If
  1475. Label1.Caption = "已经借出 " & RecNumBookFf & "本,还可以再借 " _
  1476.         & BookNum - RecNumBookFf & "本"
  1477. End Sub
  1478. Private Sub txtBookId_KeyPress(KeyAscii As Integer)
  1479. If KeyAscii = 13 Then
  1480.     LV2.ListItems.Clear
  1481.     BookId = txtBookId
  1482.     rst1.Seek "=", BookId  '查找借书证号码
  1483.     If rst1.NoMatch Then
  1484.      MsgBox "没有此借书证号码!", 0 + 48, "错误"
  1485.      txtBookId.SetFocus
  1486.      txtName.Text = ""
  1487.      txtClass.Text = ""
  1488.      txtDepart.Text = ""
  1489.      Exit Sub
  1490.     End If
  1491.         txtBookHao.Text = ""
  1492.         txtBookName.Text = ""
  1493.         txtCost.Text = ""
  1494.         txtChuBan.Text = ""
  1495.         txtLentDate.Text = ""
  1496.         txtBookBian.Text = ""
  1497.     txtBookId.Text = BookId
  1498.     txtName.Text = rst1.Fields("姓名") & vbNullString
  1499.     txtClass.Text = rst1.Fields("班级") & vbNullString
  1500.     txtDepart.Text = rst1.Fields("部门") & vbNullString
  1501.     txtZhiCheng = rst1.Fields("职称") & vbNullString
  1502.     txtFa.Text = rst1.Fields("罚款") & Empty
  1503.     txtBookBian.SetFocus
  1504.     DataRef '输出所借图书
  1505. End If
  1506. End Sub