If you need to display your sum of all rows from GridView then follow any of the solutions above.
And if you want to calculate the total using amount*rate, then add data-column to your data-source data-table as;
dataTable.Columns.Add("total", typeof(System.Double), "amount*rate");
or
dataTable.Columns.Add("grand_total", typeof(System.Double), "sum(amount)");