'表格中某列D
Dim sts,st As String
Dim drs As List(of DataRow) = DataTables("表A").Select("","_SortKey")
If drs(0)("盘") = "输" '判断第一行值是否为"A"
sts = "输"
End If
For i As Integer = 1 To drs.Count - 1
If drs(i)("盘") = drs(i-1)("盘") AndAlso drs(i)("盘") = "赢"
Continue For
Else
sts += drs(i)("盘")
End If
Next
Output.Show(sts)
Dim dic As new Dictionary(of String,Integer)
For i As Integer = 0 To sts.Split("赢").Length-2
st = sts.Split("赢")(i)
If dic.ContainsKey(st)
dic(st) += 1
Else
dic.Add(st,1)
End If
Next
For Each key As String In dic.Keys
output.show(key & ":" & dic(key))
Next