Foxtable(狐表)用户栏目专家坐堂 → 请问下面的代码是什么意思?


  共有2703人关注过本帖树形打印复制链接

主题:请问下面的代码是什么意思?

帅哥哟,离线,有人找我吗?
a272797388
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:幼狐 帖子:147 积分:1863 威望:0 精华:0 注册:2020/1/23 16:11:00
请问下面的代码是什么意思?  发帖心情 Post By:2020/11/18 12:13:00 [显示全部帖子]

 

Dim drs1 As List(Of DataRow) = DataTables("初三汤原考点").Select("代码 % 2 = 0","成绩 desc")

Dim drs2 As List(Of DataRow) = DataTables("初三汤原考点").Select("代码 % 2 = 1","成绩 desc")

Dim cnt As Integer = math.min(drs1.count,drs2.count)

Dim idx As Integer = 1

For i As Integer = 0 To cnt - 1

drs1(i)("排序") = idx

idx += 1

drs2(i)("排序") = idx

idx += 1

Next

 

 

If drs1.count > cnt Then

For i As Integer = cnt To drs1.count - 1

drs1(i)("排序") = idx

idx += 1

Next

Else

For i As Integer = cnt To drs2.count - 1

drs2(i)("排序") = idx

idx += 1

Next

End If

 

 

Tables("初三汤原考点").sort = "排序"


 回到顶部