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

📄 frmpeichang.frm

📁 大学好的可设内容
💻 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 frmpeichang 
   BackColor       =   &H00FFC0C0&
   Caption         =   "图书赔偿"
   ClientHeight    =   5865
   ClientLeft      =   3975
   ClientTop       =   3015
   ClientWidth     =   6195
   Icon            =   "frmpeichang.frx":0000
   LinkTopic       =   "Form1"
   MDIChild        =   -1  'True
   ScaleHeight     =   5865
   ScaleWidth      =   6195
   Begin MSAdodcLib.Adodc Adodc1 
      Height          =   375
      Left            =   4560
      Top             =   3360
      Width           =   1200
      _ExtentX        =   2117
      _ExtentY        =   661
      ConnectMode     =   0
      CursorLocation  =   3
      IsolationLevel  =   -1
      ConnectionTimeout=   15
      CommandTimeout  =   30
      CursorType      =   3
      LockType        =   3
      CommandType     =   2
      CursorOptions   =   0
      CacheSize       =   50
      MaxRecords      =   0
      BOFAction       =   0
      EOFAction       =   0
      ConnectStringType=   3
      Appearance      =   1
      BackColor       =   -2147483643
      ForeColor       =   -2147483640
      Orientation     =   0
      Enabled         =   -1
      Connect         =   "DSN=book"
      OLEDBString     =   ""
      OLEDBFile       =   ""
      DataSourceName  =   "book"
      OtherAttributes =   ""
      UserName        =   ""
      Password        =   ""
      RecordSource    =   "图书赔偿"
      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
   Begin VB.CommandButton Command7 
      Caption         =   "退出"
      Height          =   375
      Left            =   3120
      TabIndex        =   23
      Top             =   3360
      Width           =   1095
   End
   Begin VB.CommandButton Command6 
      Caption         =   "最后一条"
      Height          =   375
      Left            =   1920
      TabIndex        =   22
      Top             =   3360
      Width           =   975
   End
   Begin VB.CommandButton Command5 
      Caption         =   "第一条"
      Height          =   375
      Left            =   600
      TabIndex        =   21
      Top             =   3360
      Width           =   1095
   End
   Begin VB.CommandButton Command4 
      Caption         =   "上一条"
      Height          =   375
      Left            =   4560
      TabIndex        =   20
      Top             =   2880
      Width           =   1215
   End
   Begin VB.CommandButton Command3 
      Caption         =   "下一条"
      Height          =   375
      Left            =   3120
      TabIndex        =   19
      Top             =   2880
      Width           =   1095
   End
   Begin VB.CommandButton Command2 
      Caption         =   "删除记录"
      Height          =   375
      Left            =   1920
      TabIndex        =   18
      Top             =   2880
      Width           =   975
   End
   Begin VB.CommandButton Command1 
      Caption         =   "增加记录"
      Height          =   375
      Left            =   600
      TabIndex        =   17
      Top             =   2880
      Width           =   1095
   End
   Begin MSDataGridLib.DataGrid DataGrid1 
      Bindings        =   "frmpeichang.frx":2C14A
      Height          =   855
      Left            =   600
      TabIndex        =   16
      Top             =   1920
      Width           =   5295
      _ExtentX        =   9340
      _ExtentY        =   1508
      _Version        =   393216
      HeadLines       =   1
      RowHeight       =   15
      AllowAddNew     =   -1  'True
      AllowDelete     =   -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     =   2
      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
      SplitCount      =   1
      BeginProperty Split0 
         BeginProperty Column00 
         EndProperty
         BeginProperty Column01 
         EndProperty
      EndProperty
   End
   Begin VB.TextBox Text8 
      BackColor       =   &H80000018&
      DataField       =   "损害程度"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   4320
      TabIndex        =   15
      Text            =   "Text8"
      Top             =   1080
      Width           =   1575
   End
   Begin VB.TextBox Text7 
      BackColor       =   &H80000018&
      DataField       =   "姓名"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   4320
      TabIndex        =   14
      Text            =   "Text7"
      Top             =   600
      Width           =   1575
   End
   Begin VB.TextBox Text6 
      BackColor       =   &H80000018&
      DataField       =   "书名"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   4320
      TabIndex        =   13
      Text            =   "Text6"
      Top             =   120
      Width           =   1575
   End
   Begin VB.TextBox Text5 
      BackColor       =   &H80000018&
      DataField       =   "解决方案"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1440
      TabIndex        =   12
      Text            =   "Text5"
      Top             =   1560
      Width           =   4455
   End
   Begin VB.TextBox Text4 
      BackColor       =   &H80000018&
      DataField       =   "赔偿金额"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1440
      TabIndex        =   11
      Text            =   "Text4"
      Top             =   1200
      Width           =   1335
   End
   Begin VB.TextBox Text3 
      BackColor       =   &H80000018&
      DataField       =   "图书证号"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1440
      TabIndex        =   10
      Text            =   "Text3"
      Top             =   840
      Width           =   1335
   End
   Begin VB.TextBox Text2 
      BackColor       =   &H80000018&
      DataField       =   "类型"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1440
      TabIndex        =   9
      Text            =   "Text2"
      Top             =   480
      Width           =   1335
   End
   Begin VB.TextBox Text1 
      BackColor       =   &H80000018&
      DataField       =   "编号"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1440
      TabIndex        =   8
      Text            =   "Text1"
      Top             =   120
      Width           =   1335
   End
   Begin VB.Line Line4 
      BorderColor     =   &H00FF00FF&
      X1              =   480
      X2              =   6000
      Y1              =   3840
      Y2              =   3840
   End
   Begin VB.Line Line3 
      BorderColor     =   &H00FF00FF&
      X1              =   6000
      X2              =   6000
      Y1              =   120
      Y2              =   3840
   End
   Begin VB.Line Line2 
      BorderColor     =   &H00FF00FF&
      X1              =   480
      X2              =   480
      Y1              =   120
      Y2              =   3840
   End
   Begin VB.Line Line1 
      BorderColor     =   &H00FF00FF&
      X1              =   480
      X2              =   6000
      Y1              =   120
      Y2              =   120
   End
   Begin VB.Label Label8 
      Caption         =   "损害程度"
      Height          =   255
      Left            =   3480
      TabIndex        =   7
      Top             =   1080
      Width           =   735
   End
   Begin VB.Label Label7 
      Caption         =   "姓名"
      Height          =   255
      Left            =   3480
      TabIndex        =   6
      Top             =   600
      Width           =   735
   End
   Begin VB.Label Label6 
      Caption         =   "书名"
      Height          =   255
      Left            =   3480
      TabIndex        =   5
      Top             =   120
      Width           =   735
   End
   Begin VB.Label Label5 
      Caption         =   "解决方案"
      Height          =   255
      Left            =   600
      TabIndex        =   4
      Top             =   1560
      Width           =   735
   End
   Begin VB.Label Label4 
      Caption         =   "赔偿金额"
      Height          =   255
      Left            =   600
      TabIndex        =   3
      Top             =   1200
      Width           =   735
   End
   Begin VB.Label Label3 
      Caption         =   "图书证号"
      Height          =   255
      Left            =   600
      TabIndex        =   2
      Top             =   840
      Width           =   735
   End
   Begin VB.Label Label2 
      Caption         =   "类型"
      Height          =   255
      Left            =   600
      TabIndex        =   1
      Top             =   480
      Width           =   735
   End
   Begin VB.Label Label1 
      Caption         =   "编号"
      Height          =   255
      Left            =   600
      TabIndex        =   0
      Top             =   120
      Width           =   735
   End
End
Attribute VB_Name = "frmpeichang"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
On Error GoTo adderr
Text1.SetFocus
Adodc1.Recordset.AddNew
Exit Sub
adderr:
MsgBox Err.Description
End Sub

Private Sub Command2_Click()
On Error GoTo deleteerr

  With Adodc1.Recordset
 If Not .EOF And Not .BOF Then
     If MsgBox("删除当前记录吗?", vbYesNo + vbQuestion) = vbYes Then
     .Delete
     .MoveNext
 If .EOF Then .MoveLast
  
     End If
    End If
   
Exit Sub
End With

 
deleteerr:
MsgBox Err.Description
End Sub

Private Sub Command3_Click()
Adodc1.Recordset.MoveNext
If Adodc1.Recordset.EOF Then
MsgBox "这是最后一条记录", vbOKCancel + vbQuestion
   Adodc1.Recordset.MoveLast
End If
End Sub

Private Sub Command4_Click()
Adodc1.Recordset.MovePrevious
If Adodc1.Recordset.BOF Then
MsgBox "这是第一条记录", vbOKCancel + vbQuestion
Adodc1.Recordset.MoveFirst
End If
End Sub

Private Sub Command5_Click()
If Adodc1.Recordset.EOF Then
MsgBox "记录空", vbOKCancel + vbQuestion
End
Else
Adodc1.Recordset.MoveFirst
End If
Exit Sub
End Sub

Private Sub Command6_Click()
If Adodc1.Recordset.RecordCount = 0 Then
MsgBox "空记录", vbOKCancel + vbQuestion
End
Else
Adodc1.Recordset.MoveLast
End If
End Sub

Private Sub Command7_Click()

frmpeichang.Hide
End Sub


⌨️ 快捷键说明

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