protected void BindgvSouce() { string depment = this.txtDepmentName.Value.Trim(); string userName = this.txtUserName.Value.Trim(); System.DateTime inputDate = string.IsNullOrEmpty(this.txtInputDate.Text.Trim()) ? System.DateTime.Now : System.Convert.ToDateTime(this.txtInputDate.Text.Trim()); DataTable indirectOrgCosts = EReport.GetIndirectOrgCosts(depment, userName, inputDate); this.gvCostInOrgList.DataSource = indirectOrgCosts; this.gvCostInOrgList.DataBind(); this.RowSpanTalbe(1, 3, this.gvCostInOrgList); this.ViewState["gvwdataSouce"] = indirectOrgCosts; this.ViewState["gvwCostIndirectOrg"] = this.Formatdata(indirectOrgCosts); string[] sumAmount = this.GetSumAmount(indirectOrgCosts); int[] index = new int[] { 7, 9, 12, 14 }; GridViewUtility.AddTotalRow(this.gvCostInOrgList, sumAmount, index); }