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

📄 frmscore.frm

📁 VB+access学生信息管理系统,基本完成了学生信息的添加,修改,打印,查询功能.大家互相学习吧.
💻 FRM
📖 第 1 页 / 共 2 页
字号:
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"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{0BA686C6-F7D3-101A-993E-0000C0EF6F5E}#1.0#0"; "THREED32.OCX"
Begin VB.Form frmScore 
   Caption         =   "成绩信息"
   ClientHeight    =   3465
   ClientLeft      =   1710
   ClientTop       =   5895
   ClientWidth     =   15210
   LinkTopic       =   "Form1"
   LockControls    =   -1  'True
   MDIChild        =   -1  'True
   MinButton       =   0   'False
   ScaleHeight     =   3465
   ScaleWidth      =   15210
   WindowState     =   2  'Maximized
   Begin Threed.SSPanel SSPanel1 
      Height          =   495
      Left            =   240
      TabIndex        =   0
      Top             =   360
      Width           =   4575
      _Version        =   65536
      _ExtentX        =   8070
      _ExtentY        =   873
      _StockProps     =   15
      Caption         =   "学 生 成 绩 记 录"
      ForeColor       =   8388608
      BackColor       =   12632256
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "宋体"
         Size            =   15.75
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BevelOuter      =   1
      Font3D          =   1
   End
   Begin Threed.SSPanel SSPanel2 
      Height          =   555
      Left            =   60
      TabIndex        =   1
      Top             =   960
      Width           =   15135
      _Version        =   65536
      _ExtentX        =   26696
      _ExtentY        =   979
      _StockProps     =   15
      BackColor       =   12632256
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BevelOuter      =   1
      Begin VB.ComboBox xqComb 
         Height          =   300
         ItemData        =   "frmScore.frx":0000
         Left            =   10080
         List            =   "frmScore.frx":001C
         Style           =   2  'Dropdown List
         TabIndex        =   15
         Top             =   120
         Width           =   855
      End
      Begin VB.ComboBox kcComb 
         Height          =   300
         ItemData        =   "frmScore.frx":0038
         Left            =   11460
         List            =   "frmScore.frx":003A
         Style           =   2  'Dropdown List
         TabIndex        =   13
         Top             =   120
         Width           =   3555
      End
      Begin VB.ComboBox xyComb 
         Height          =   300
         Left            =   2160
         Style           =   2  'Dropdown List
         TabIndex        =   5
         Top             =   120
         Width           =   2535
      End
      Begin VB.ComboBox bjComb 
         Height          =   300
         ItemData        =   "frmScore.frx":003C
         Left            =   8580
         List            =   "frmScore.frx":005E
         Style           =   2  'Dropdown List
         TabIndex        =   4
         Top             =   120
         Width           =   975
      End
      Begin VB.ComboBox zyComb 
         Height          =   300
         Left            =   5100
         Style           =   2  'Dropdown List
         TabIndex        =   3
         Top             =   120
         Width           =   3015
      End
      Begin VB.ComboBox njComb 
         Height          =   300
         ItemData        =   "frmScore.frx":008A
         Left            =   540
         List            =   "frmScore.frx":00A3
         Style           =   2  'Dropdown List
         TabIndex        =   2
         Top             =   120
         Width           =   1155
      End
      Begin VB.Label Label6 
         Alignment       =   2  'Center
         Caption         =   "学期"
         Height          =   255
         Left            =   9600
         TabIndex        =   14
         Top             =   180
         Width           =   435
      End
      Begin VB.Label Label5 
         Alignment       =   2  'Center
         Caption         =   "课程"
         Height          =   255
         Left            =   10980
         TabIndex        =   12
         Top             =   180
         Width           =   435
      End
      Begin VB.Label Label1 
         Alignment       =   2  'Center
         Caption         =   "学院"
         Height          =   255
         Left            =   1740
         TabIndex        =   9
         Top             =   180
         Width           =   435
      End
      Begin VB.Label Label4 
         Alignment       =   2  'Center
         Caption         =   "班级"
         Height          =   255
         Left            =   8160
         TabIndex        =   8
         Top             =   180
         Width           =   435
      End
      Begin VB.Label Label3 
         Alignment       =   2  'Center
         Caption         =   "专业"
         Height          =   255
         Left            =   4740
         TabIndex        =   7
         Top             =   180
         Width           =   375
      End
      Begin VB.Label Label2 
         Alignment       =   2  'Center
         Caption         =   "年级"
         Height          =   255
         Left            =   120
         TabIndex        =   6
         Top             =   180
         Width           =   435
      End
   End
   Begin MSDataGridLib.DataGrid DataGrid1 
      Bindings        =   "frmScore.frx":00D1
      Height          =   1395
      Left            =   180
      TabIndex        =   10
      Top             =   1620
      Width           =   8055
      _ExtentX        =   14208
      _ExtentY        =   2461
      _Version        =   393216
      AllowUpdate     =   -1  'True
      AllowArrows     =   -1  'True
      DefColWidth     =   100
      HeadLines       =   2
      RowHeight       =   17
      TabAction       =   2
      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 
         ScrollBars      =   3
         BeginProperty Column00 
         EndProperty
         BeginProperty Column01 
         EndProperty
      EndProperty
   End
   Begin MSComctlLib.StatusBar StatBar 
      Align           =   2  'Align Bottom
      Height          =   405
      Left            =   0
      TabIndex        =   11
      Top             =   3060
      Width           =   15210
      _ExtentX        =   26829
      _ExtentY        =   714
      _Version        =   393216
      BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
         NumPanels       =   3
         BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
            Object.Width           =   3881
            MinWidth        =   3881
         EndProperty
         BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
            Object.Width           =   3528
            MinWidth        =   3528
         EndProperty
         BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
            AutoSize        =   1
            Object.Width           =   18838
            Picture         =   "frmScore.frx":00E6
         EndProperty
      EndProperty
   End
   Begin MSAdodcLib.Adodc Adodc1 
      Height          =   375
      Left            =   9960
      Top             =   2160
      Visible         =   0   'False
      Width           =   2595
      _ExtentX        =   4577
      _ExtentY        =   661
      ConnectMode     =   0
      CursorLocation  =   3
      IsolationLevel  =   -1
      ConnectionTimeout=   15
      CommandTimeout  =   30
      CursorType      =   1
      LockType        =   4
      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         =   ""
      OLEDBString     =   ""
      OLEDBFile       =   ""
      DataSourceName  =   ""
      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
End
Attribute VB_Name = "frmScore"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Dim cn As New ADODB.Connection  '连接对象
Dim DataEdited As Boolean  '数据已编辑标志
Dim bFirstStart As Boolean '窗体首次启动的标志

Private Sub Form_Load()
Dim msql$, mrs As ADODB.Recordset, sArray() As String
    '窗体中心定位
    Call CenterPos(StudentMIS, Me)
    DataEdited = False
    bFirstStart = True
    '年级组合框
    njComb.ListIndex = 0 '显示第一项
    '填充学院组合框
    msql$ = "select distinct institute.institute_name,lessons.institute_id from" _
    & " institute,lessons where institute.institute_id=lessons.institute_id " & _
    " order by lessons.institute_id asc"
    Set mrs = ExecuteSQL(msql)
    Call ADDComboListRS(xyComb, mrs, False, "institute_name", "institute_id")
    '填充专业组合框
    sArray = Split(xyComb.Text)
    msql = "select distinct major.major_name,lessons.institute_id," & _
            "lessons.major_id from major,lessons where " _
            & " lessons.institute_id='" & sArray(1) & "'" _
            & " and lessons.institute_id=major.institute_id " _
            & " and major.major_id=lessons.major_id " & _
            "order by lessons.institute_id,lessons.major_id asc"
    Set mrs = ExecuteSQL(msql)
    Call ADDComboListRS(zyComb, mrs, False, "major_name", "institute_id", "major_id")
    '班级组合框
    bjComb.ListIndex = 0 '显示第一项
    '学期组合框
    xqComb.ListIndex = 0
    '填充课程组合框
    sArray = Split(zyComb.Text)
    msql$ = "select distinct lesson_id,lesson_name from lessons where institute_id='" _
        & sArray(1) & "'" & " and major_id='" & sArray(2) & "'" & "  and term='" _
        & xqComb.Text & "'" & " order by lesson_id asc"
    Set mrs = ExecuteSQL(msql)
    Call ADDComboListRS(kcComb, mrs, False, "lesson_name", "lesson_id")
    '设置ADO控件
    Call SetAdc
End Sub

'设置ADO数据控件的连接属性和记录源属性
Private Sub SetAdc()
Dim szyArray() As String, skcArray() As String
    szyArray = Split(zyComb.Text): skcArray = Split(kcComb.Text)
    Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" _
                             & StudentDBfile & ";Persist Security Info=False"
    Adodc1.RecordSource = "select score.number as 学号,score.name as 姓名," _
    & "score.lesson_id as 课程代码," & "score.score as 成绩,score.memo as 备注 " _

⌨️ 快捷键说明

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