Tables("选课数据表").Filter = "[测评科目] = '测评' and [机考安排] <> '不排考'"
Tables("选课数据表").Sort = "试卷号,学号"
If Tables("选课数据表").Rows.Count > 0 Then
Tables("选课数据表").Select(0,0,Tables("选课数据表").Rows.count - 1,Tables("选课数据表").Cols.count - 1 )
Dim Book1 As New XLS.Book(ProjectPath & "Attachments\测评科目学员表.xls")
Dim fl As String = ProjectPath & "Reports\测评类科目学员分数表.xls"
Book1.Build() '生成细节区
Book1.Save(fl) '保存工作簿
End If
Tables("选课数据表").Filter = "[论文类安排] = '论文类安排' and [机考安排] <> '不排考'"
Tables("选课数据表").Sort = "试卷号,学号"
If Tables("选课数据表").Rows.Count > 0 Then
Tables("选课数据表").Select(0,0,Tables("选课数据表").Rows.count - 1,Tables("选课数据表").Cols.count - 1 )
Dim Book2 As New XLS.Book(ProjectPath & "Attachments\论文类科目学员表.xls")
Dim fl2 As String = ProjectPath & "Reports\论文类科目学员分数表.xls"
Book2.Build() '生成细节区
Book2.Save(fl) '保存工作簿
End If
Tables("选课数据表").filter = ""