title: Change the Column Name in Datatable in C#
body: <p>I trying to change the column name of the DataTable but some how I lost the data.</p>
  
  <pre><code>foreach (DataRow dr in item)
      Ds.Tables[0].ImportRow(dr);                           
  
  Table.Columns[0].ColumnName = "Barcode";
  Table.Columns[1].ColumnName = "Description";
  Table.Columns[2].ColumnName = "Price";
  Table.Columns[3].ColumnName = "Cost";
  Table.Columns[4].ColumnName = "Stock";
  Table.Columns[5].ColumnName = "Dept #";
  
  updateDgv.DataSource = Table;
  </code></pre>