tbl.Table.DataTable.DataRows.Clear
Dim drs1 As List(of DataRow) = DataTables("比赛积分").SQLSelect("[团体赛或个人赛] = '" & lx & "' And [棋赛名称] = '" & di1 & "' And [第几轮比赛] = '" & di2 & "'","","排序")
Dim pz As List(of DataRow) = DataTables("比赛积分").SQLSelect("[团体赛或个人赛] = '" & lx & "' And [棋赛名称] = '" & di1 & "' And [第几轮比赛] = '" & di2 & "' And [排序] =" & dr("排序"))
Messagebox.show(drs1.Count)
if pz.count= 2
For i As Integer = 0 To drs1.Count - 1
Dim nr As DataRow = tbl.Table.DataTable.AddNew()
If i <= drs1.Count And rand.Next(0,2) = 0 Then
……
endif
rand.Next(0,1) 永远都是0,next包含最小值,不包含最大值