以下是引用有点甜在2013-12-31 21:11:00的发言:
Dim t As Table = Tables("xxx")For Each r As Row In t.Rows
Dim over As Boolean = False
For i As Integer = 4 To 21
If r(t.Cols(i).Name) < 60 Then
r("备注") = "不及格"
over = True
Exit For
End If
Next
If over = False Then
If r("综合成绩") > 90 Then
r("备注") = "优秀"
Else If r("综合成绩") > 80 Then
r("备注") = "良好"
Else If r("综合成绩") > 70 Then
r("备注") = "中等"
Else If r("综合成绩") > 60 Then
r("备注") = "合格"
Else
r("备注") = "不合格"
End If
End If
Next
太感谢你了,这些代码我一星期也想不到,这个代码我看懂了,可是把这个代码写在那个事件呢,还是另加一个按钮呢、?