DataTable table = dsProject_SH.Tables[1]; decimal count = 0; foreach (DataRow dr in table.Rows) { count += Convert.ToDecimal(dr["Weightage"]); } Label lblWeightage = (Label)dg_Drawing_Appl.FooterRow.FindControl("lblWeightage"); lblWeightage.Visible = true; lblWeightage.Text = count.ToString();
FindControl
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)