Usa questa funzione per ripulirlo dai doppioni:
public DataTable cleanDataTable(DataTable dt)
{
DataTable dtCopy = new DataTable();
dtCopy.Columns.Add(new DataColumn("ID"));
dtCopy.Columns.Add(new DataColumn("Quant"));
dtCopy.AcceptChanges();
for (int i = 0; i < dt.Rows.Count; i++)
{
DataRow[] drc = dtCopy.Select("ID='" + dt.Rows[i][0].ToString() + "'");
if (drc.Length==0)
{
DataRow dr = dtCopy.NewRow();
dr[0]=dt.Rows[i][0];
dr[1] = dt.Rows[i][1];
dtCopy.Rows.Add(dr);
}
}
dtCopy.AcceptChanges();
return dtCopy;
}