2.主界面
paper51.com
主界面代码: http://www.paper51.com Option Explicit 内容来自www.paper51.com '表示当前的用户类型 copyright paper51.com
'0---管理员类型的用户; 1---教师类型的用户 http://www.paper51.com Public mnUserType As Integer 内容来自论文无忧网 www.paper51.com
'表示当前登录的用户名 内容来自论文无忧网 www.paper51.com
Public msUserName As String 内容来自论文无忧网 www.paper51.com Private Sub MDIForm_Activate() paper51.com ''根据不同的用户类型,使相应的菜单项可见 copyright paper51.com
Select Case mnUserType 内容来自www.paper51.com
Case 0: '以管理员身份登录 内容来自www.paper51.com mnuFind.Visible = True paper51.com Case 1: '以教师身份登录, 只能查询自己的信息 内容来自论文无忧网 www.paper51.com mnuFind.Visible = False 内容来自论文无忧网 www.paper51.com End Select copyright paper51.com
End Sub copyright paper51.com Private Sub MDIForm_QueryUnload(Cancel As Integer, UnloadMode AsInteger) copyright paper51.com If MsgBox("真的要对出本系统吗?", vbQuestion + vbYesNo+ vbDefaultButton2, "退出") = vbNo Then 内容来自论文无忧网 www.paper51.com
Cancel = 1 内容来自www.paper51.com End If http://www.paper51.com End Sub 内容来自www.paper51.com
Private Sub mnuAbout_Click() copyright paper51.com Load frmSplash paper51.com
frmSplash.mbAbout= True 内容来自论文无忧网 www.paper51.com
frmSplash.ShowvbModal http://www.paper51.com End Sub 内容来自www.paper51.com Private Sub mnuExit_Click() 内容来自www.paper51.com
Unload Me 内容来自www.paper51.com End Sub copyright paper51.com Private Sub mnuFind_Click() copyright paper51.com frmTeacher.Show paper51.com frmTeacher.cmdSeek.Value= True paper51.com End Sub http://www.paper51.com Private Sub mnuLogin_Click() paper51.com If MsgBox("若重新登录,所有窗体都将关闭!是否重新登录?", vbQuestion + vbYesNo+ vbDefaultButton2, "重新登录") = vbYes Then copyright paper51.com
Unload MDIMain 内容来自www.paper51.com frmLogin.Show http://www.paper51.com End If 内容来自www.paper51.com End Sub http://www.paper51.com
copyright paper51.com
|