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

📄 form2.frm

📁 基于VB的一个小程序
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Form2 
   Caption         =   "Form2"
   ClientHeight    =   3855
   ClientLeft      =   60
   ClientTop       =   450
   ClientWidth     =   4680
   LinkTopic       =   "Form2"
   ScaleHeight     =   3855
   ScaleWidth      =   4680
   StartUpPosition =   3  'Windows Default
   Begin VB.CommandButton Command2 
      Caption         =   "退出"
      Height          =   375
      Left            =   2400
      TabIndex        =   12
      Top             =   3360
      Width           =   1695
   End
   Begin VB.CommandButton Command1 
      Caption         =   "确定"
      Height          =   375
      Left            =   600
      TabIndex        =   11
      Top             =   3360
      Width           =   1575
   End
   Begin VB.Data Data1 
      Caption         =   "Data1"
      Connect         =   "Access"
      DatabaseName    =   "D:\myvb\stu.mdb"
      DefaultCursorType=   0  'DefaultCursor
      DefaultType     =   2  'UseODBC
      Exclusive       =   0   'False
      Height          =   375
      Left            =   360
      Options         =   0
      ReadOnly        =   0   'False
      RecordsetType   =   1  'Dynaset
      RecordSource    =   "班级学生信息表"
      Top             =   2880
      Visible         =   0   'False
      Width           =   3975
   End
   Begin VB.Frame Frame2 
      Caption         =   "查询结果"
      Height          =   1335
      Left            =   360
      TabIndex        =   6
      Top             =   1440
      Width           =   3975
      Begin VB.TextBox Text4 
         Enabled         =   0   'False
         Height          =   405
         Left            =   1200
         TabIndex        =   8
         Top             =   720
         Width           =   2535
      End
      Begin VB.TextBox Text3 
         Enabled         =   0   'False
         Height          =   375
         Left            =   1200
         TabIndex        =   7
         Top             =   240
         Width           =   2535
      End
      Begin VB.Label Label4 
         BackStyle       =   0  'Transparent
         Caption         =   "手机"
         Height          =   255
         Left            =   120
         TabIndex        =   10
         Top             =   720
         Width           =   615
      End
      Begin VB.Label Label3 
         BackStyle       =   0  'Transparent
         Caption         =   "寝室电话"
         Height          =   375
         Left            =   120
         TabIndex        =   9
         Top             =   240
         Width           =   855
      End
   End
   Begin VB.Frame Frame1 
      Caption         =   "查询方式"
      Height          =   1215
      Left            =   360
      TabIndex        =   0
      Top             =   120
      Width           =   3975
      Begin VB.TextBox Text1 
         Height          =   375
         Left            =   1680
         TabIndex        =   13
         Top             =   240
         Width           =   1935
      End
      Begin VB.TextBox Text2 
         Height          =   375
         Left            =   1680
         TabIndex        =   5
         Top             =   720
         Width           =   1935
      End
      Begin VB.CheckBox Check2 
         Caption         =   "Check2"
         Height          =   255
         Left            =   360
         TabIndex        =   3
         Top             =   840
         Width           =   255
      End
      Begin VB.CheckBox Check1 
         Height          =   255
         Left            =   360
         TabIndex        =   2
         Top             =   360
         Width           =   255
      End
      Begin VB.Label Label2 
         BackStyle       =   0  'Transparent
         Caption         =   "姓名"
         Height          =   255
         Left            =   960
         TabIndex        =   4
         Top             =   840
         Width           =   375
      End
      Begin VB.Label Label1 
         BackStyle       =   0  'Transparent
         Caption         =   "学号"
         Height          =   255
         Left            =   960
         TabIndex        =   1
         Top             =   360
         Width           =   375
      End
   End
End
Attribute VB_Name = "Form2"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Text3.Text = ""
Text4.Text = ""
Data1.Recordset.FindFirst "学号='" + Text1.Text + "'"
If Data1.Recordset.NoMatch = True Then
MsgBox "查无此人", , "查询提示"
Else
Text3.Text = Data1.Recordset("寝室电话")
Text4.Text = Data1.Recordset("手机")
End If

End Sub

Private Sub Command2_Click()
End
End Sub

Private Sub Form_Paint()
Dim i As Integer
ScaleMode = 3
For i = 0 To 255
Line (0, i)-(Width, i), RGB(i, i, 255)
Next i
End Sub

⌨️ 快捷键说明

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