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

📄 form7.frm

📁 这是朋友一起做的 这是一个关于学生成绩管理系统的VS程序 谢谢大家提意见
💻 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 Form7 
   BackColor       =   &H00FFC0C0&
   Caption         =   "选课管理"
   ClientHeight    =   4485
   ClientLeft      =   3060
   ClientTop       =   2835
   ClientWidth     =   6795
   LinkTopic       =   "Form7"
   ScaleHeight     =   4485
   ScaleWidth      =   6795
   Begin VB.TextBox Text6 
      DataField       =   "studentid"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   1320
      TabIndex        =   12
      Top             =   6840
      Visible         =   0   'False
      Width           =   375
   End
   Begin VB.TextBox Text5 
      DataField       =   "courseid"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   960
      TabIndex        =   11
      Top             =   6960
      Visible         =   0   'False
      Width           =   375
   End
   Begin VB.TextBox Text4 
      DataField       =   "courseid"
      DataSource      =   "Adodc1"
      Height          =   270
      Left            =   600
      TabIndex        =   10
      Top             =   6960
      Visible         =   0   'False
      Width           =   375
   End
   Begin VB.TextBox Text3 
      Height          =   375
      Left            =   240
      TabIndex        =   9
      Top             =   3840
      Width           =   1335
   End
   Begin MSAdodcLib.Adodc Adodc1 
      Height          =   330
      Left            =   1560
      Top             =   6120
      Visible         =   0   'False
      Width           =   1335
      _ExtentX        =   2355
      _ExtentY        =   582
      ConnectMode     =   0
      CursorLocation  =   3
      IsolationLevel  =   -1
      ConnectionTimeout=   15
      CommandTimeout  =   30
      CursorType      =   3
      LockType        =   3
      CommandType     =   8
      CursorOptions   =   0
      CacheSize       =   50
      MaxRecords      =   0
      BOFAction       =   0
      EOFAction       =   0
      ConnectStringType=   1
      Appearance      =   1
      BackColor       =   -2147483643
      ForeColor       =   -2147483640
      Orientation     =   0
      Enabled         =   -1
      Connect         =   "Provider=Microsoft.Jet.OLEDB.3.51;Persist Security Info=False;Data Source=db1.mdb"
      OLEDBString     =   "Provider=Microsoft.Jet.OLEDB.3.51;Persist Security Info=False;Data Source=db1.mdb"
      OLEDBFile       =   ""
      DataSourceName  =   ""
      OtherAttributes =   ""
      UserName        =   ""
      Password        =   ""
      RecordSource    =   "select * from studentcourse"
      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 Command2 
      BackColor       =   &H00C0C0C0&
      Caption         =   "退选"
      Height          =   375
      Left            =   4680
      Style           =   1  'Graphical
      TabIndex        =   7
      Top             =   3840
      Width           =   1215
   End
   Begin VB.TextBox Text2 
      Height          =   375
      Left            =   3360
      TabIndex        =   6
      Top             =   3840
      Width           =   1095
   End
   Begin VB.CommandButton Command1 
      BackColor       =   &H00C0C0C0&
      Caption         =   "选修"
      Height          =   375
      Left            =   4680
      Style           =   1  'Graphical
      TabIndex        =   4
      Top             =   3360
      Width           =   1215
   End
   Begin VB.TextBox Text1 
      Height          =   375
      Left            =   3360
      TabIndex        =   3
      Top             =   3360
      Width           =   1095
   End
   Begin VB.Frame Frame1 
      BackColor       =   &H00FFC0C0&
      Caption         =   "显示选课信息"
      Height          =   2895
      Left            =   120
      TabIndex        =   0
      Top             =   240
      Width           =   6495
      Begin MSDataGridLib.DataGrid DataGrid1 
         Bindings        =   "Form7.frx":0000
         Height          =   2295
         Left            =   240
         TabIndex        =   1
         Top             =   360
         Width           =   5775
         _ExtentX        =   10186
         _ExtentY        =   4048
         _Version        =   393216
         HeadLines       =   1
         RowHeight       =   15
         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
   End
   Begin VB.Label Label3 
      BackColor       =   &H00FFC0C0&
      Caption         =   "要操作的学号"
      Height          =   255
      Left            =   240
      TabIndex        =   8
      Top             =   3480
      Width           =   1215
   End
   Begin VB.Label Label2 
      BackColor       =   &H00FFC0C0&
      Caption         =   "要退选的课程"
      Height          =   255
      Left            =   1920
      TabIndex        =   5
      Top             =   3960
      Width           =   1215
   End
   Begin VB.Label Label1 
      BackColor       =   &H00FFC0C0&
      Caption         =   "要选修的课程"
      Height          =   255
      Left            =   1920
      TabIndex        =   2
      Top             =   3480
      Width           =   1215
   End
End
Attribute VB_Name = "Form7"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
If Text1.Text = "" Then
MsgBox "请输入要选修的课程"
Exit Sub
End If

If Text3.Text = "" Then
MsgBox "请输入要操作的学号"
Exit Sub
End If

Adodc1.Recordset.MoveLast
Adodc1.Recordset.MoveNext
Adodc1.Recordset.AddNew
Text6.Text = Text3.Text
Text4.Text = Text1.Text
Adodc1.Recordset.Update
DataGrid1.Refresh
Adodc1.Recordset.MoveFirst
End Sub

Private Sub Command2_Click()
If Text2.Text = "" Then
MsgBox "请输入要退选的课程"
Exit Sub
End If
If Text3.Text = "" Then
MsgBox "请输入要操作的学号"
Exit Sub
End If
Adodc1.Recordset.MoveFirst
Do
    If Text3.Text = Text6.Text And Text2.Text = Text5.Text Then
    Adodc1.Recordset.Delete
    DataGrid1.Refresh
    Exit Do
    Else
    MsgBox "请从新输入操作数"
    Exit Do
    End If
   Adodc1.Recordset.MoveNext
  Loop
End Sub

⌨️ 快捷键说明

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