protected void btnSave_Click(object sender, EventArgs e) { string strIsn = string.Empty; string res = string.Empty; string process = string.Empty; string duedate = string.Empty; int TotalQty = 0; DataSet Ds_Header = BAL.BALFactory.Instance.BAL_New_Bookings.FillHeaderInfo(Globals.BranchID); if (Ds_Header.Tables[0].Rows.Count > 0) { duedate = (DateTime.Parse(date[0].ToString()).AddDays(Convert.ToInt32(Ds_Header.Tables[0].Rows[0]["DateOffSet"].ToString()))).ToString("dd MMM yyyy"); } for (int i = 0; i < grdReport.Rows.Count; i++) { if (((CheckBox)grdReport.Rows[i].FindControl("chkSelect")).Checked) { strIsn = grdReport.Rows[i].Cells[1].Text; process = grdReport.Rows[i].Cells[4].Text; TotalQty += 1; res = BAL.BALFactory.Instance.BAL_City.SaveRedo(Globals.BranchID, txtInvoiceNo.Text, Convert.ToInt32(strIsn), process, duedate, TotalQty); } } if (res == "Record Saved") { lblErr.Text = "Record Sucessfully"; BindGrid(txtInvoiceNo.Text); } Response.Write(PrjClass.GetAndGo("Booking Accepted. Booking Number is : " + txtInvoiceNo.Text, "../Bookings/RedoSlip.aspx?BN=" + txtInvoiceNo.Text + "-1" + date[0].ToString() + "&DirectPrint=true&RedirectBack=true&closeWindow=true" + "false")); }