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

📄 学生管理系统3.txt

📁 学生学藉管理 系统:A simple student information management system.
💻 TXT
📖 第 1 页 / 共 2 页
字号:
   End 
   Begin VB.Menu file  
      Caption         =   "文件(&f)" 
      WindowList      =   -1  'True 
      Begin VB.Menu xsda  
         Caption         =   "学生成绩管理系统" 
      End 
      Begin VB.Menu jsjxgl  
         Caption         =   "教师教学管理系统" 
      End 
      Begin VB.Menu jsgzgl  
         Caption         =   "教师工资管理系统" 
      End 
      Begin VB.Menu ex  
         Caption         =   "退出(&x)" 
      End 
   End 
   Begin VB.Menu edit  
      Caption         =   "编辑(&e)" 
      Begin VB.Menu add  
         Caption         =   "添加" 
      End 
      Begin VB.Menu del  
         Caption         =   "删除" 
      End 
   End 
   Begin VB.Menu end  
      Caption         =   "返回" 
      Begin VB.Menu exit  
         Caption         =   "返回" 
      End 
   End 
   Begin VB.Menu tj  
      Caption         =   "添加新用户" 
      Begin VB.Menu tj1  
         Caption         =   "添加" 
      End 
   End 
End 
Attribute VB_Name = "Form1" 
Attribute VB_GlobalNameSpace = False 
Attribute VB_Creatable = False 
Attribute VB_PredeclaredId = True 
Attribute VB_Exposed = False 
Dim db As Database 
Dim da As Recordset 
 
Private Sub add_Click() 
  newclass = Text1.Text 
  newname = Text2.Text 
  newsex = Text3.Text 
  newcsdate = Text6.Text 
  newtelephon = Text4.Text 
  newadress = Text5.Text 
  newnumber = Text7.Text 
  With da 
  .AddNew 
  !Class = LCase(newclass) 
  !Name = LCase(newname) 
  !sex = LCase(newsex) 
  !csdate = LCase(newcsdate) 
  !telephon = LCase(newtelephon) 
  !adress = LCase(newadress) 
  !Number = LCase(newnumber) 
  .Update 
  End With 
  'MsgBox (newName & "was added to the address book") 
  If MsgBox("是否添加下一条记录!", vbOKCancel) = vbOK Then 
    Text1.Text = "" 
    Text2.Text = "" 
    Text3.Text = "" 
    Text4.Text = "" 
    Text5.Text = "" 
    Text6.Text = "" 
    Text7.Text = "" 
Else 
    GoTo ine 
End If 
ine: 
End Sub 
 
Private Sub Command1_Click() 
  On Error Resume Next 
  da.MovePrevious 
  Text1 = da.Fields("class") 
  Text2 = da.Fields("name") 
  Text3 = da.Fields("sex") 
  Text4 = da.Fields("telephon") 
  Text5 = da.Fields("adress") 
  Text6 = da.Fields("csdate") 
  Text7 = da.Fields("number") 
End Sub 
 
Private Sub Command2_Click() 
  newclass = Text1.Text 
  newname = Text2.Text 
  newsex = Text3.Text 
  newcsdate = Text6.Text 
  newtelephon = Text4.Text 
  newadress = Text5.Text 
  newnumber = Text7.Text 
  With da 
  .AddNew 
  !Class = LCase(newclass) 
  !Name = LCase(newname) 
  !sex = LCase(newsex) 
  !csdate = LCase(newcsdate) 
  !telephon = LCase(newtelephon) 
  !adress = LCase(newadress) 
  !Number = LCase(newnumber) 
  .Update 
  End With 
  'MsgBox (newName & "was added to the address book") 
  If MsgBox("是否添加下一条记录!", vbOKCancel) = vbOK Then 
    Text1.Text = "" 
    Text2.Text = "" 
    Text3.Text = "" 
    Text4.Text = "" 
    Text5.Text = "" 
    Text6.Text = "" 
    Text7.Text = "" 
Else 
    GoTo ine 
End If 
ine: 
End Sub 
 
Private Sub Command3_Click() 
 
Set da = db.OpenRecordset("select * from da") 
numberquery = InputBox("请输入您所查找的人的学号:", "查询") 
If MsgBox("请您确定的确要查询此人吗!", 6) <> 1 Then 
  Exit Sub 
End If 
   
Do Until da.EOF 
If da.Fields("number") Like "*" & LCase(numberquery) & "*" Then 
  Text1 = da.Fields("class") 
  Text2 = da.Fields("name") 
  Text3 = da.Fields("sex") 
  Text4 = da.Fields("telephon") 
  Text5 = da.Fields("adress") 
  Text6 = da.Fields("csdate") 
  Text7 = da.Fields("number") 
  Exit Sub 
Else 
  da.MoveNext 
End If 
  Loop 
End Sub 
 
Private Sub Command4_Click() 
 da.MoveFirst 
 Text1 = da.Fields("class") 
 Text2 = da.Fields("name") 
 Text3 = da.Fields("sex") 
 Text4 = da.Fields("telephon") 
 Text5 = da.Fields("adress") 
 Text6 = da.Fields("csdate") 
 Text7 = da.Fields("number") 
End Sub 
 
Private Sub Command5_Click() 
  If MsgBox("是否修改!", vbOKCancel + vbExclamation, "警告!") = vbOK Then 
   newclass = Text1.Text 
   newname = Text2.Text 
   newsex = Text3.Text 
   newtelephon = Text4.Text 
   newadress = Text5.Text 
   newcsdate = Text6.Text 
   newnumber = Text7.Text 
 With da 
  .AddNew 
  !Class = LCase(newclass) 
  !Name = LCase(newname) 
  !sex = LCase(newsex) 
  !telephon = LCase(newtelephon) 
  !adress = LCase(newadress) 
  !csdate = LCase(newcsdate) 
  !Number = LCase(newnumber) 
  .Update 
 End With 
 Else 
  Exit Sub 
 End If 
End Sub 
 
Private Sub Command6_Click() 
 Set da = db.OpenRecordset("select * from da where da.name") 
  da.Delete 
  da.MoveNext 
  Text1.Text = "" 
  Text2.Text = "" 
  Text3.Text = "" 
  Text4.Text = "" 
  Text5.Text = "" 
  Text6.Text = "" 
  Text7.Text = "" 
End Sub 
 
Private Sub Command7_Click() 
On Error Resume Next 
 da.MoveNext 
 Text1 = da.Fields("class") 
 Text2 = da.Fields("name") 
 Text3 = da.Fields("sex") 
 Text6 = da.Fields("csdate") 
 Text4 = da.Fields("telephon") 
 Text5 = da.Fields("adress") 
 Text7 = da.Fields("number") 
End Sub 
 
Private Sub del_Click() 
  Set da = db.OpenRecordset("select * from da where da.name") 
  da.Delete 
  da.MoveNext 
  Text1.Text = "" 
  Text2.Text = "" 
  Text3.Text = "" 
  Text4.Text = "" 
  Text5.Text = "" 
  Text6.Text = "" 
  Text7.Text = "" 
End Sub 
 
Private Sub exit_Click() 
   Me.Hide 
   frmSplash.Show 
End Sub 
 
Private Sub Form_Load() 
  Set db = OpenDatabase(App.Path & "\学生档案管理数据库") 
  Set da = db.OpenRecordset("da") 
  If da.EOF Then 
    MsgBox "please add someone to the databse" 
  Else 
    da.MoveFirst 
    Text1 = da.Fields("class") 
    Text2 = da.Fields("name") 
    Text3 = da.Fields("sex") 
    Text4 = da.Fields("telephon") 
    Text5 = da.Fields("adress") 
    Text6 = da.Fields("csdate") 
    Text7 = da.Fields("number") 
  End If 
 
End Sub 
 
 
 
 
Private Sub jsgzgl_Click() 
     Form3.Show 
End Sub 
 
Private Sub jsjxgl_Click() 
  Form2.Show 
End Sub 
 
 
Private Sub tj1_Click() 
  Form5.Show 
End Sub 
 
Private Sub xsda_Click() 
   
  Form4.Show 
End Sub 
Private Sub Form_Resize() 
    Form1.Height = 6450 
    Form1.Width = 7665 
    Move (Screen.Width - Me.Width) / 2, (Screen.Height - Me.Height) / 2 
End Sub 
 







⌨️ 快捷键说明

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