【发布时间】:2014-04-25 07:55:31
【问题描述】:
从 C# 中的数据表中选择数据时出现问题。我正在用这个填充一个组合框。第 1 列重复了不同的描述。这是我正在使用的代码。
var comboItems = this.coreDataSet.Tables["TimesheetDataTable"].AsEnumerable()
.Select(row => row.Field<string>("column 1") + " (" + row.Field<string>("description") + ")")
.Distinct()
.ToList();
提前致谢
【问题讨论】: