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

📄 学籍添加.frm

📁 一个学生管理系统。较为完整
💻 FRM
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "msadodc.ocx"
Begin VB.Form Form6 
   Caption         =   "Form6"
   ClientHeight    =   4500
   ClientLeft      =   60
   ClientTop       =   450
   ClientWidth     =   8130
   LinkTopic       =   "Form6"
   ScaleHeight     =   4500
   ScaleWidth      =   8130
   StartUpPosition =   3  '窗口缺省
   Begin MSAdodcLib.Adodc Adodc1 
      Height          =   735
      Left            =   4920
      Top             =   5280
      Visible         =   0   'False
      Width           =   2175
      _ExtentX        =   3836
      _ExtentY        =   1296
      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         =   ""
      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
   Begin VB.CommandButton Command2 
      Caption         =   "Command2"
      Height          =   495
      Left            =   4200
      TabIndex        =   13
      Top             =   3480
      Width           =   1815
   End
   Begin VB.CommandButton Command1 
      Caption         =   "Command1"
      Height          =   495
      Left            =   1320
      TabIndex        =   12
      Top             =   3480
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   0
      Left            =   2040
      TabIndex        =   5
      Top             =   480
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   1
      Left            =   5400
      TabIndex        =   4
      Top             =   480
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   2
      Left            =   2040
      TabIndex        =   3
      Top             =   1320
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   3
      Left            =   5400
      TabIndex        =   2
      Top             =   1320
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   4
      Left            =   2040
      TabIndex        =   1
      Top             =   2400
      Width           =   1815
   End
   Begin VB.TextBox Text1 
      Height          =   495
      Index           =   5
      Left            =   5400
      TabIndex        =   0
      Top             =   2400
      Width           =   1815
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   0
      Left            =   600
      TabIndex        =   11
      Top             =   480
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   1
      Left            =   4080
      TabIndex        =   10
      Top             =   600
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   2
      Left            =   600
      TabIndex        =   9
      Top             =   1440
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   3
      Left            =   4080
      TabIndex        =   8
      Top             =   1440
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   4
      Left            =   600
      TabIndex        =   7
      Top             =   2520
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "Label1"
      Height          =   375
      Index           =   5
      Left            =   4080
      TabIndex        =   6
      Top             =   2520
      Width           =   1455
   End
End
Attribute VB_Name = "Form6"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Adodc1.Recordset.AddNew
For i = 0 To 5
Adodc1.Recordset(i).Value = Text1(i).Text
Next i
Adodc1.Recordset.Update
Adodc1.Refresh
MsgBox "您添加成功了!!!"
End Sub

Private Sub Command2_Click()
For i = 0 To 5
Text1(i).Text = ""
Next i
Text1(0).SetFocus

End Sub

Private Sub Form_Load()


Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\student1.mdb;Persist Security Info=False"
Adodc1.RecordSource = "student"
Adodc1.Refresh
Me.Caption = "学籍添加"
'Set DataGrid1.DataSource = Adodc1
'DataGrid1.Refresh
For i = 0 To 5
Label1(0).Caption = "学    号:"
Label1(1).Caption = "姓    名:"
Label1(2).Caption = "年    龄:"
Label1(3).Caption = "性    别:"
Label1(4).Caption = "班    级:"
Label1(5).Caption = "联系电话:"
'Text1(i).Text = Adodc1.Recordset(i).Value
Next i
Command1.Caption = "确定添加"
Command2.Caption = "取消添加"
'Text1(0).SetFocus

End Sub

⌨️ 快捷键说明

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