?? frmmain.frm
字號:
VERSION 5.00
Begin VB.Form frmMain
Caption = "學生信息管理系統"
ClientHeight = 4530
ClientLeft = 1875
ClientTop = 1980
ClientWidth = 6360
Icon = "frmMain.frx":0000
LinkTopic = "Form1"
MouseIcon = "frmMain.frx":030A
Picture = "frmMain.frx":0614
ScaleHeight = 4530
ScaleWidth = 6360
Begin VB.Line Line1
BorderColor = &H00808080&
X1 = 0
X2 = 6360
Y1 = 0
Y2 = 0
End
Begin VB.Menu mnuSystem
Caption = "系統(&S)"
Begin VB.Menu mnuAddUser
Caption = "添加用戶(&A)"
End
Begin VB.Menu mnuDelUser
Caption = "刪除用戶(&D)"
End
Begin VB.Menu mnuModiPurview
Caption = "更改權限(&R)"
End
Begin VB.Menu mnuPassWord
Caption = "修改密碼(&P)"
End
Begin VB.Menu BarS1
Caption = "-"
End
Begin VB.Menu mnuExit
Caption = "退出系統(&X)"
End
End
Begin VB.Menu mnuEssential
Caption = "學籍管理(&E)"
Begin VB.Menu mnuNew
Caption = "添加學籍信息(&N)"
End
Begin VB.Menu mnuModiEss
Caption = "修改學籍信息(&M)"
End
Begin VB.Menu mnuQueryEss
Caption = "查詢學籍信息(&Q)"
End
End
Begin VB.Menu mnuCourse
Caption = "課程管理(&C)"
Begin VB.Menu mnuAddCourse
Caption = "添加課程(&A)"
End
Begin VB.Menu mnuModiCourse
Caption = "修改課程(&M)"
End
End
Begin VB.Menu mnuGrade
Caption = "成績管理(&G)"
Begin VB.Menu mnuInputGrade
Caption = "輸入成績(&I)"
End
Begin VB.Menu mnuModiGrade
Caption = "修改成績(&M)"
End
Begin VB.Menu mnuQueryGrade
Caption = "查詢成績(&Q)"
End
End
Begin VB.Menu mnuHelp
Caption = "幫助(&H)"
Begin VB.Menu mnuAbout
Caption = "關于(&A)..."
End
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'主窗體frmMain
Option Explicit
Private Sub Form_Initialize()
ChDrive App.Path
ChDir App.Path
Me.WindowState = vbMaximized
End Sub
Private Sub Form_Load()
'根據用戶權限確定是否顯示用戶管理各菜單項
mnuAddUser.Visible = gblnPurview
mnuDelUser.Visible = gblnPurview
mnuModiPurview.Visible = gblnPurview
Call CreateConnection
End Sub
Private Sub Form_Resize() '窗體改變大小
If Me.WindowState = vbMinimized Then Exit Sub
If Me.Width < 6000 Then Me.Width = 6000
If Me.Height < 5000 Then Me.Height = 5000
Me.Refresh
End Sub
Private Sub mnuAbout_Click() '關于
MsgBox Space(6) & "數據庫課程試驗" & Space(6) & vbCr & vbCr & Space(9) & "NO.47 孫永勝"
End Sub
Private Sub mnuAddCourse_Click() '添加課程
frmAddCourse.Show
Me.Hide
End Sub
Private Sub mnuAddUser_Click() '添加用戶
frmUser.Show
Me.Hide
End Sub
Private Sub mnuDelUser_Click() '刪除用戶
frmDelUser.Caption = "刪除用戶"
frmDelUser.Show
Me.Hide
End Sub
Private Sub mnuExit_Click() '退出
Unload Me
End Sub
Private Sub Form_Unload(Cancel As Integer) '主窗體卸載
On Error GoTo Quit
Dim i As Integer
Set pubCnn = Nothing
For i = Forms.Count - 1 To 0 Step -1
Unload Forms(i)
Next
Exit Sub
Quit:
End '出錯時強制退出
End Sub
Private Sub mnuInputGrade_Click() '輸入成績
frmInGrade.Show
Me.Hide
End Sub
Private Sub mnuModiCourse_Click() '修改課程信息
frmModiCourse.Show
Me.Hide
End Sub
Private Sub mnuModiEss_Click() '修改學籍信息
frmModiEss.Show
Me.Hide
End Sub
Private Sub mnuModiGrade_Click() '修改成績
frmModiGrade.Show
Me.Hide
End Sub
Private Sub mnuModiPurview_Click()
frmDelUser.Caption = "更改用戶權限"
frmDelUser.Show
Me.Hide
End Sub
Private Sub mnuNew_Click() '添加學籍信息
frmAddEss.Show
Me.Hide
End Sub
Private Sub mnuPassWord_Click() '修改密碼
frmModiPass.Show
Me.Hide
End Sub
Private Sub mnuQueryEss_Click() '查詢學籍信息
frmQueryEss.Show
Me.Hide
End Sub
Private Sub mnuQueryGrade_Click() '查詢成績信息
frmQueryGrade.Show
Me.Hide
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -