做个按钮
Dim dt As DataTable = DataTables("表A")
For Each dr As DataRow In dt.Select("")
Dim ary() As Double = {dr("A裁判"), dr("B裁判"), dr("C裁判"), dr("D裁判")}
array.sort(ary)
dr("最低分") = ary(0)
dr("最高分") = ary(ary.length-1)
dr("平均分") = (ary(1) + ary(2)) / 2
Next
Dim drs As List(Of DataRow) = dt.Select("", "平均分 desc")
For n As Integer = 0 To drs.Count - 1 '遍历所有行
If n > 0 AndAlso drs(n)("平均分") = drs(n-1)("平均分") Then '如果总分和上一行相同
drs(n)("排名") = drs(n-1)("排名") '则排名等于上一行
Else
drs(n)("排名") = n + 1 '设置排名
End If
Next