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

📄 form1.frm

📁 Visual Basic 6 大学教程的代码
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "Using the Data Envrionment Designer"
   ClientHeight    =   3555
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   5100
   LinkTopic       =   "Form1"
   ScaleHeight     =   3555
   ScaleWidth      =   5100
   StartUpPosition =   3  'Windows Default
   Begin VB.CommandButton cmdNext 
      Caption         =   "Next Record"
      Height          =   375
      Left            =   2640
      TabIndex        =   17
      Top             =   3120
      Width           =   2415
   End
   Begin VB.CommandButton cmdPrevious 
      Caption         =   "Previous Record"
      Height          =   375
      Left            =   120
      TabIndex        =   16
      Top             =   3120
      Width           =   2415
   End
   Begin VB.TextBox txtComments 
      DataField       =   "Comments"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   15
      Top             =   2730
      Width           =   3375
   End
   Begin VB.TextBox txtSubject 
      DataField       =   "Subject"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   13
      Top             =   2355
      Width           =   3375
   End
   Begin VB.TextBox txtNotes 
      DataField       =   "Notes"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   11
      Top             =   1980
      Width           =   3375
   End
   Begin VB.TextBox txtDescription 
      DataField       =   "Description"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   9
      Top             =   1590
      Width           =   3375
   End
   Begin VB.TextBox txtPubID 
      DataField       =   "PubID"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   7
      Top             =   1215
      Width           =   690
   End
   Begin VB.TextBox txtISBN 
      DataField       =   "ISBN"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   5
      Top             =   840
      Width           =   3300
   End
   Begin VB.TextBox txtYearPublished 
      DataField       =   "Year Published"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   3
      Top             =   450
      Width           =   690
   End
   Begin VB.TextBox txtTitle 
      DataField       =   "Title"
      DataMember      =   "Command1"
      DataSource      =   "DataEnvironment1"
      Height          =   285
      Left            =   1485
      TabIndex        =   1
      Top             =   75
      Width           =   3375
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Comments:"
      Height          =   255
      Index           =   7
      Left            =   -360
      TabIndex        =   14
      Top             =   2775
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Subject:"
      Height          =   255
      Index           =   6
      Left            =   -360
      TabIndex        =   12
      Top             =   2400
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Notes:"
      Height          =   255
      Index           =   5
      Left            =   -360
      TabIndex        =   10
      Top             =   2025
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Description:"
      Height          =   255
      Index           =   4
      Left            =   -360
      TabIndex        =   8
      Top             =   1635
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "PubID:"
      Height          =   255
      Index           =   3
      Left            =   -360
      TabIndex        =   6
      Top             =   1260
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "ISBN:"
      Height          =   255
      Index           =   2
      Left            =   -360
      TabIndex        =   4
      Top             =   885
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Year Published:"
      Height          =   255
      Index           =   1
      Left            =   -360
      TabIndex        =   2
      Top             =   495
      Width           =   1815
   End
   Begin VB.Label lblFieldLabel 
      Alignment       =   1  'Right Justify
      AutoSize        =   -1  'True
      Caption         =   "Title:"
      Height          =   255
      Index           =   0
      Left            =   -360
      TabIndex        =   0
      Top             =   120
      Width           =   1815
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
' Fig. 18.26
' Using the Data Environment Designer
Option Explicit

Private Sub cmdNext_Click()
   DataEnvironment1.rsCommand1.MoveNext
   cmdPrevious.Enabled = True
   
   If DataEnvironment1.rsCommand1.EOF = True Then
      cmdNext.Enabled = False
   End If
End Sub

Private Sub cmdPrevious_Click()
   DataEnvironment1.rsCommand1.MovePrevious
   cmdNext.Enabled = True
   
   If DataEnvironment1.rsCommand1.BOF = True Then
      cmdPrevious.Enabled = False
   End If
End Sub

⌨️ 快捷键说明

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