var query = (from row in playerSpotAndValue.AsEnumerable()
where !row.Field<string>("RunningTotal").Contains("/")
group row by row.Field<UInt16>("SpotID") into spotID
orderby spotID.Key
select new
{
SpotID = spotID.Key,
HandTotal= spotID.Max(p => Convert.ToUInt16(p.Field<string>("RunningTotal"))),
RowsCount = spotID.Count()
});
如何在此查询中使用 CopyToDataTable 以便我可以这样查询
query.CopyToDataTable().Rows[0]["HandTotal"].ToString();