已阅读5页,还剩16页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
Form1的代码:Private Sub Command1_Click()Unload MeForm3.ShowEnd SubPrivate Sub Command2_Click()Unload MeForm2.ShowEnd SubPrivate Sub Command3_Click()If MsgBox(确定退出管理系统?, _ vbQuestion + vbYesNo + vbDefaultButton2, 警告!) = vbYes ThenEndEnd IfEnd SubPrivate Sub Picture1_Click()End SubPrivate Sub Timer1_Timer()Command4.Caption = Time$() End SubPrivate Sub Form_Load()Timer1.Interval = 1000Timer1.Enabled = TrueEnd SubForm2的代码:Private Sub Command1_Click()Adodc1.Recordset.MoveFirst Adodc1.Recordset.Find 用户名= & Text1.Text & If Adodc1.Recordset.EOF = True Then Adodc1.Recordset.MoveFirst If (Trim(Text1.Text) = (Trim(Text3.Text) And (Trim(Text2.Text) = (Trim(Text4.Text) Then Adodc1.Enabled = False Form4.Text3.Text = Text1.Text Unload Me Form8.Show Else MsgBox 非法的账号!, vbOKOnly + vbExclamation, 请重新输入! Text1.Text = Text2.Text = Text1.SetFocus End IfEnd SubPrivate Sub Command2_Click()Text1.Text = Text2.Text = End SubPrivate Sub Command3_Click()Unload MeForm1.ShowEnd SubPrivate Sub Form_Load()Text2.Text = Text1.Text = Text2.PasswordChar = *End SubPrivate Sub Picture1_Click()End SubForm3的代码:Private Sub Command1_Click()Adodc1.Recordset.MoveFirst Adodc1.Recordset.Find 用户名= & Text1.Text & If Adodc1.Recordset.EOF = True Then Adodc1.Recordset.MoveFirst If (Trim(Text1.Text) = (Trim(Text3.Text) And (Trim(Text2.Text) = (Trim(Text4.Text) Then Adodc1.Enabled = False Form4.Text1.Text = Text1.Text Form4.Text2.Text = Text4.Text Unload Me Form5.Show Else MsgBox 非法的账号!, vbOKOnly + vbExclamation, 请重新输入! Text1.Text = Text2.Text = Text1.SetFocus End IfEnd SubPrivate Sub Command2_Click() Option1.Value = False Option2.Value = False Text1.Text = Text2.Text = End SubPrivate Sub Command3_Click()Unload MeForm1.ShowEnd SubPrivate Sub Form_Load()Text2.Text = Text1.Text = Text2.PasswordChar = *End Sub无代码Form5的代码:Private Sub cjcx_Click(Index As Integer)Unload MeForm7.ShowEnd SubPrivate Sub Command1_Click()On Error Resume Next If Command1.Caption = 修改 Then Command1.Caption = 确认 Adodc2.Recordset.Requery Text5.SetFocus Else Command1.Caption = 修改 Adodc2.Recordset.Update MsgBox 修改成功 End IfEnd SubPrivate Sub Form_Load()Adodc1.CommandType = adCmdUnknownAdodc1.RecordSource = Select * From studentwel Where 用户名 = & Form4.Text1.Text & Adodc1.Refresh Text1.Visible = TrueText3.Visible = TrueTimer1.Interval = 1000Timer1.Enabled = TrueEnd SubPrivate Sub Picture1_Click()End SubPrivate Sub tcxt_Click(Index As Integer)Unload MeForm3.ShowEnd SubPrivate Sub Timer1_Timer()Text2.Text = Time$() End SubPrivate Sub xgmm_Click()Label5.Visible = TrueLabel7.Visible = TrueText4.Visible = TrueText5.Visible = TrueCommand1.Visible = TrueAdodc2.CommandType = adCmdUnknownAdodc2.RecordSource = Select * From studententer Where 用户名 = & Form4.Text1.Text & Adodc2.RefreshEnd SubPrivate Sub xxcx_Click(Index As Integer)Unload MeForm6.ShowEnd SubForm6的代码:Private Sub Command1_Click()Unload MeForm5.ShowEnd SubPrivate Sub Command2_Click()On Error Resume Next If Command2.Caption = 修改 Then Text1.SetFocus Command2.Caption = 确认 Adodc1.Recordset.Requery MsgBox 信息修改成功 Else Command2.Caption = 修改 Adodc1.Recordset.Update End If End SubPrivate Sub Form_Load()Adodc1.CommandType = adCmdUnknownAdodc1.RecordSource = Select * From studentinfor Where 学号 = & Form4.Text1.Text & Adodc1.Refresh Text1.Visible = TrueText2.Visible = TrueText3.Visible = TrueText4.Visible = TrueText5.Visible = TrueText6.Visible = TrueText7.Visible = TrueText8.Visible = TrueEnd SubPrivate Sub Picture1_Click()End SubPrivate Sub Command1_Click()Unload MeForm5.ShowEnd SubPrivate Sub Form_Load()Adodc1.Recordset.MoveFirst Dim a As String a = Form4.Text1.Text Adodc1.Recordset.Find 学号= & a & Text1.Visible = TrueText2.Visible = TrueText4.Visible = TrueText6.Visible = TrueDim b As Integerb = Text2.TextIf b = 90 ThenText3.Text = 优ElseIf b = 80 ThenText3.Text = 良ElseIf b = 70 ThenText3.Text = 中ElseIf b = 60 ThenText3.Text = 及格ElseText3.Text = 不及格End IfDim c As Integerc = Text4.TextIf c = 90 ThenText5.Text = 优ElseIf c = 80 ThenText5.Text = 良ElseIf c = 70 ThenText5.Text = 中ElseIf c = 60 ThenText5.Text = 及格ElseText5.Text = 不及格End IfDim d As Integerd = Text6.TextIf d = 90 ThenText7.Text = 优ElseIf d = 80 ThenText7.Text = 良ElseIf d = 70 ThenText7.Text = 中ElseIf d = 60 ThenText7.Text = 及格ElseText7.Text = 不及格End IfIf Text3.Text = 不及格 ThenText2.ForeColor = &HFF&End IfIf Text5.Text = 不及格 ThenText4.ForeColor = &HFF&End IfIf Text7.Text = 不及格 ThenText6.ForeColor = &HFF&End IfEnd SubPrivate Sub Picture1_Click()End SubForm8的代码:Private Sub Command1_Click()On Error Resume Next If Command1.Caption = 修改 Then Command1.Caption = 确认 Adodc1.Recordset.Requery Text2.SetFocus Else Command1.Caption = 修改 Adodc1.Recordset.Update MsgBox 修改成功 End IfEnd SubPrivate Sub file1_Click()Unload MeForm10.ShowEnd SubPrivate Sub file2_Click()Unload MeForm9.ShowEnd SubPrivate Sub file4_Click()Unload MeForm12.ShowEnd SubPrivate Sub file5_Click()Unload MeForm11.ShowEnd SubPrivate Sub file7_Click()Unload MeForm2.ShowEnd SubPrivate Sub file8_Click()Label3.Visible = TrueLabel4.Visible = TrueText1.Visible = TrueText2.Visible = TrueCommand1.Visible = TrueAdodc1.CommandType = adCmdUnknownAdodc1.RecordSource = Select * From teacherenter Where 用户名 = & Form4.Text3.Text & Adodc1.RefreshEnd SubPrivate Sub Picture1_Click()End SubForm9的代码:Private Sub Command1_Click()Dim mno As String mno = InputBox(请输入学号, 查找窗) Adodc1.Recordset.MoveFirst Adodc1.Recordset.Find 学号= & mno & If Adodc1.Recordset.EOF = True Then MsgBox 无此学号!, , 提示End SubPrivate Sub Command2_Click()Unload MeForm8.ShowEnd SubPrivate Sub Command3_Click()Dim mnon As String mnon = InputBox(请输入姓名, 查找窗) Adodc1.Recordset.MoveFirst Adodc1.Recordset.Find 姓名= & mnon & If Adodc1.Recordset.EOF = True Then MsgBox 无此学号!, , 提示End SubPrivate Sub Label5_Click()End SubPrivate Sub Label7_Click()End SubForm10的代码:Private Sub Command1_Click()On Error Resume Next Command2.Enabled = Not Command2.Enabled Command3.Enabled = Not Command3.Enabled Command4.Enabled = Not Command4.Enabled If Command1.Caption = 新增 Then Command1.Caption = 确认 Adodc1.Recordset.AddNew Text1.SetFocus Else Command1.Caption = 新增 Adodc1.Recordset.Update Adodc1.Recordset.MoveLast End IfEnd SubPrivate Sub Command2_Click()On Error Resume Next Adodc1.Recordset.Delete Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End IfEnd SubPrivate Sub Command3_Click()On Error Resume Next Command1.Enabled = Not Command1.Enabled Command2.Enabled = Not Command2.Enabled Command4.Enabled = Not Command4.Enabled If Command3.Caption = 修改 Then Command3.Caption = 确认 Adodc1.Recordset.Requery Text1.SetFocus Else Command3.Caption = 修改 Adodc1.Recordset.Update End IfEnd SubPrivate Sub Command4_Click()On Error Resume Next Command1.Caption = 新增 Command3.Caption = 修改 Command1.Enabled = True Command2.Enabled = True Command3.Enabled = True Command4.Enabled = True Adodc1.Recordset.CancelUpdate Adodc1.Recordset.MoveLastEnd SubPrivate Sub Command5_Click()Unload MeForm8.ShowEnd SubPrivate Sub Command6_Click()Adodc1.Recordset.MovePreviousIf Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveLast End IfEnd SubPrivate Sub Command7_Click()Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveFirst End IfEnd SubPrivate Sub Command8_Click()Adodc1.Recordset.MoveFirstEnd SubPrivate Sub Command9_Click()Adodc1.Recordset.MoveLastEnd SubPrivate Sub Label5_Click()End SubForm11的代码:Private Sub Command1_Click()Dim mno As String mno = InputBox(请输入学号, 查找窗) Adodc1.Recordset.MoveFirst Adodc1.Recordset.Find 学号= & mno & If Adodc1.Recordset.EOF = True Then MsgBox 无此学号!, , 提示End SubPrivate Sub Command2_Click()Unload MeForm8.ShowEnd SubPrivate Sub Picture1_Click()End SubForm12的代码:Private Sub Command1_Click()On Error Resume Next Command2.Enabled = Not Command2.Enabled Command3.Enabled = Not Command3.Enabled Command4.Enabled = Not Command4.Enabled If Command1.Caption = 新增 Then Command1.Caption = 确认 Adodc1.Recordset.AddNew Text1.SetFocus Else Command1.Caption = 新增 Adodc1.Recordset.Update Adodc1.Recordset.MoveLast End IfEnd SubPrivate Sub Command2_Click()On Error Resume Next Adodc1.Recordset.Delete Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End IfEnd SubPrivate Sub Command3_Click()On Error Resume Next Command1.Enabled = Not Command1.Enabled Command2.Enabled = Not Command2.Enabled C
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 分析化验基础试题及参考答案
- 事业改革拔高试题及答案探讨
- 2026年心理控制考试题库(含答案)
- 母婴护理员基础知识模拟题题库及答案详解
- 2026年高级育婴师高级考试模拟题及答案详解
- 2026年劳资考试题库(含答案)
- 2026年煤炭采样考试题库(含答案)
- 2026年仁怀水务考试题库(含答案)
- 2026年妇产科主治医师妊娠合并病毒性肝炎练习模拟题及答案详解
- 2026年国开电大专科中国古代文学(B)在线形考(形考任务1)模拟题及答案详解
- 2026年农发银行笔试题库及答案详解
- 2026年辽宁中考改革试题及答案
- 人工智能+数据安全治理可行性研究报告
- 2026年世界阿尔茨海默病日课件
- 调压器考试试卷及答案详解
- 2026年云南省昆明市辅警考试题库(附答案)
- 工贸企业三级安全教育考试试题及答案
- 布袋除尘器移除施工技术方案
- 教师职业倦怠组织支持研究论文
- 2026年心理咨询师(初级)职业技能鉴定考试试卷(含答案)
- 2026中国职业教育虚拟仿真实训基地建设标准
评论
0/150
提交评论