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

📄 form4.frm

📁 一个比较适合做毕业设计的程序
💻 FRM
📖 第 1 页 / 共 2 页
字号:
      ForeColor       =   &H000000FF&
      Height          =   7215
      Left            =   360
      TabIndex        =   0
      Top             =   2040
      Width           =   7095
      Begin VB.TextBox Text13 
         BackColor       =   &H00FFFFFF&
         DataField       =   "附注"
         DataSource      =   "Adodc1"
         Height          =   1335
         Left            =   1320
         MultiLine       =   -1  'True
         ScrollBars      =   2  'Vertical
         TabIndex        =   27
         Top             =   5160
         Width           =   5295
      End
      Begin VB.TextBox Text2 
         BackColor       =   &H00FFFFFF&
         DataField       =   "班级"
         DataSource      =   "Adodc1"
         Height          =   375
         Left            =   1320
         TabIndex        =   16
         Top             =   1440
         Width           =   1335
      End
      Begin VB.TextBox Text1 
         BackColor       =   &H00FFFFFF&
         DataField       =   "学号"
         DataSource      =   "Adodc1"
         Height          =   375
         Left            =   1320
         TabIndex        =   2
         Top             =   840
         Width           =   1335
      End
      Begin VB.Label Label14 
         BackColor       =   &H00C0FFC0&
         Caption         =   "附注:"
         ForeColor       =   &H00FF0000&
         Height          =   495
         Left            =   240
         TabIndex        =   15
         Top             =   5280
         Width           =   1095
      End
      Begin VB.Label Label13 
         BackColor       =   &H00C0FFC0&
         Caption         =   "专业:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   3480
         TabIndex        =   14
         Top             =   3840
         Width           =   1575
      End
      Begin VB.Label Label12 
         BackColor       =   &H00C0FFC0&
         Caption         =   "院系:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   3480
         TabIndex        =   13
         Top             =   3240
         Width           =   1575
      End
      Begin VB.Label Label11 
         BackColor       =   &H00C0FFC0&
         Caption         =   "电话号码:"
         ForeColor       =   &H00FF0000&
         Height          =   615
         Left            =   3480
         TabIndex        =   12
         Top             =   2640
         Width           =   1335
      End
      Begin VB.Label Label10 
         BackColor       =   &H00C0FFC0&
         Caption         =   "邮政编码:"
         ForeColor       =   &H00FF0000&
         Height          =   495
         Left            =   3480
         TabIndex        =   11
         Top             =   2040
         Width           =   1095
      End
      Begin VB.Label Label9 
         BackColor       =   &H00C0FFC0&
         Caption         =   "地址:"
         ForeColor       =   &H00FF0000&
         Height          =   495
         Left            =   3480
         TabIndex        =   10
         Top             =   1440
         Width           =   1335
      End
      Begin VB.Label Label8 
         BackColor       =   &H00C0FFC0&
         Caption         =   "父母姓名:"
         ForeColor       =   &H00FF0000&
         Height          =   495
         Left            =   3480
         TabIndex        =   9
         Top             =   840
         Width           =   1335
      End
      Begin VB.Label Label7 
         BackColor       =   &H00C0FFC0&
         Caption         =   "民族:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   240
         TabIndex        =   8
         Top             =   3840
         Width           =   1215
      End
      Begin VB.Label Label6 
         BackColor       =   &H00C0FFC0&
         Caption         =   "出生年月:"
         ForeColor       =   &H00FF0000&
         Height          =   615
         Left            =   240
         TabIndex        =   7
         Top             =   3240
         Width           =   1215
      End
      Begin VB.Label Label5 
         BackColor       =   &H00C0FFC0&
         Caption         =   "性别:"
         ForeColor       =   &H00FF0000&
         Height          =   495
         Left            =   240
         TabIndex        =   6
         Top             =   2640
         Width           =   855
      End
      Begin VB.Label Label3 
         BackColor       =   &H00C0FFC0&
         Caption         =   "姓名:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   240
         TabIndex        =   4
         Top             =   2040
         Width           =   1215
      End
      Begin VB.Label Label2 
         BackColor       =   &H00C0FFC0&
         Caption         =   "班级:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   240
         TabIndex        =   3
         Top             =   1440
         Width           =   1095
      End
      Begin VB.Label Label1 
         BackColor       =   &H00C0FFC0&
         Caption         =   "学号:"
         ForeColor       =   &H00FF0000&
         Height          =   375
         Left            =   240
         TabIndex        =   1
         Top             =   840
         Width           =   1335
      End
   End
   Begin VB.Label Label4 
      Caption         =   "Label4"
      Height          =   495
      Left            =   3480
      TabIndex        =   5
      Top             =   3120
      Width           =   1215
   End
End
Attribute VB_Name = "frmInfo"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
On Error GoTo error:
 If Text14.Text <> "" Then
     If Option1.Value Then searchSQL = "SELECT * FROM 学生 WHERE 学号=" & "'" & Text14.Text & "'"
     If Option2.Value Then searchSQL = "SELECT *  FROM 学生   where 班级=" & "'" & Text14.Text & "'  order by 学号 asc" 'in (select 学号 from 学生 where 班级= '" & Trim(Text1.Text) & " ')"
    'If Option3.Value Then searchSQL = "SELECT * FROM 学生与课程 "
 Else
     MsgBox "条件不能为空,请输入查询依据!", vbOKOnly + vbExclamation, "警告"
     Exit Sub
     
 End If
Adodc1.RecordSource = searchSQL
Adodc1.Refresh
If Option1.Value Then
    If Adodc1.Recordset.EOF Then
        MsgBox "没有这个学生!", vbOKOnly + vbExclamation, "警告"
    End If
Else
   If Adodc1.Recordset.EOF Then
        MsgBox "没有这个班级!", vbOKOnly + vbExclamation, "警告"
   End If
End If
Exit Sub
error:
    MsgBox Err.Description
End Sub


Private Sub Command2_Click()
Unload Me
End Sub

Private Sub Command3_Click()
On Error GoTo AddErr
 If Option2.Value Then
     Adodc1.Recordset.MoveFirst
     Exit Sub
End If
Exit Sub
AddErr:
    MsgBox Err.Description
 
End Sub

Private Sub Command4_Click()
On Error GoTo AddErr
If Option2.Value Then
        If Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveLast
        Adodc1.Recordset.MovePrevious
        Exit Sub
End If
Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command5_Click()
On Error GoTo AddErr
If Option2.Value Then
        If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveFirst
        Adodc1.Recordset.MoveNext
        Exit Sub
End If
Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command6_Click()
On Error GoTo AddErr
 If Option2.Value Then
      Adodc1.Recordset.MoveLast
      Exit Sub
End If
Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Form_Load()
MakeCenter frmInfo
End Sub

Private Sub Label16_Click()
End Sub

⌨️ 快捷键说明

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