DataTable testtable = new DataTable();
testtable.Columns.Add("ID");
testtable.Columns.Add("ProductName");
testtable.Rows.Add("1", "1");
testtable.Rows.Add("1", "1");
testtable.Rows.Add("1", "1");
testtable.Rows.Add("2", "2");
testtable.Rows.Add("3", "3");
DataTable finalltable = new DataTable();
finalltable = testtable.Clone();
finalltable.Clear();
var rows = from row in testtable.AsEnumerable() group row by row["ID"] into myrow select myrow.FirstOrDefault();
foreach (DataRow row in rows)
{
finalltable.ImportRow(row);
}