Private Sub Text1_Change()
End Sub
课程统计分析(如:界面如图辣)
(图辣)
代码如下:
Private Sub Command1_Click()
Dim SQLoriginal As String
Dim SQLadd As String
Dim SQLorder As String
Dim strSql As String
SQLoriginal = "SELECT * FROM 课程表 "
SQLadd = "WHERE 专业=专业 AND 课程名称=课程名称 "
SQLorder = ""
If Check1.Value = 1 And Not IsNull(Text1) Then
SQLadd = SQLadd + "and 专业='" + Text1 + "'"
End If
If Check2.Value = 1 And Not IsNull(Combo1) Then
SQLadd = SQLadd + "and 课程性质='" + Combo1 + "'"
End If
'If Check3.Value = 1 And Not IsNumeric(Text2) Then
'SQLadd = SQLadd + "and 课时='" + Text2 + "'"
'End If
If Check4.Value = 1 And Not IsNull(Text3) Then
SQLadd = SQLadd + "and 课程名称='" + Text3 + "'"
End If
strSql = SQLoriginal + SQLadd + SQLorde
If Dat_Main.rsDat_Grean.State = 1 Then
Dat_Main.rsDat_Grean.Close
End If
Dat_Main.rsDat_Grean.Open strSql
Dat_Grean.Show vbModal
Text1.Text = ""
Combo1.Text = ""
'Text2.Text = ""
Text3.Text = ""
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
Text1.Text = ""
'Text2.Text = ""
Text3.Text = ""
Combo1.Text = ""
Combo1.AddItem ("必修")
Combo1.AddItem ("选修")
Combo1.AddItem ("自开")
End Sub
Private Sub Text3_Change()
End Sub
成绩统计分析(如:界面如图七)
(图七)
代码如下:
Private Sub Command1_Click()
Dim SQLoriginal As String
Dim SQLadd As String
Dim SQLorder As String
Dim strSql As String
On Error Resume Next
SQLoriginal = "SELECT * FROM 成绩表 "
SQLadd = "WHERE 学号=学号 AND 姓名=姓名 "
SQLorder = ""
If Check1.Value = 1 And IsNumeric(Text1) Then
SQLadd = SQLadd + "and 学号='" + Text1 + "'"
End If
If Check2.Value = 1 And Not IsNull(Text2) Then
SQLadd = SQLadd + "and 姓名='" + Text2 + "'"
End If
If Check3.Value = 1 And Not IsNull(Text3) Then
SQLadd = SQLadd + "and 考试科目='" + Text3 + "'"
End If
If Check4.Value = 1 Then
SQLadd = SQLadd + "and 科目分数<60"
End If
strSql = SQLoriginal + SQLadd + SQLorde
If Dat_Main.rsDat_ChengJ.State = 1 Then
Dat_Main.rsDat_ChengJ.Close
End If
Dat_Main.rsDat_ChengJ.Open strSql
Dat_ChengJ.Show vbModal
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
'Text4.Text = ""
End Sub
Private Sub Text1_Change()
End Sub
交费统计分析(如:界面如图八)
(图八)
代码如下:
Private Sub Command1_Click()
Dim SQLoriginal As String
Dim SQLadd As String
Dim SQLorder As String
Dim strSql As String
SQLoriginal = "SELECT 学号,姓名,学期,本学期应交费用,实际交费,本次欠费 FROM 交费表 "
SQLadd = "WHERE 学号=学号 AND 姓名=姓名 "
SQLorder = ""
If Check1.Value = 1 And IsNumeric(Text1) Then
SQLadd = SQLadd + "and 学号='" + Text1 + "'"
End If
If Check2.Value = 1 And Not IsNull(Text2) Then
SQLadd = SQLadd + "and 姓名='" + Text2 + "'"
End If
If Check3.Value = 1 And IsNumeric(Text3) Then
SQLadd = SQLadd + "and 实际交费='" + Text3 + "'"
End If
If Check4.Value = 1 And IsNumeric(Text4) Then
SQLadd = SQLadd + "and 本次欠费='" + Text4 + "'"
End If
strSql = SQLoriginal + SQLadd + SQLorde
If Dat_Main.rsDat_JiaoF.State = 1 Then
上一页 [1] [2] [3] [4] [5] [6] [7] [8] 下一页