protected void BtnDelete_Click(object sender, EventArgs e) { CustomerTransactionBo customerTransactionBo = new CustomerTransactionBo(); string HiddenVal = hdnStatusValue.Value; int transactionId = 0; if (Session["TransactionId"] != null) { transactionId = int.Parse(Session["TransactionId"].ToString()); } if (HiddenVal == "1") { if (hddeletiontype.Value == "Bulk") { string transid = Session["TransId"].ToString(); customerTransactionBo.BulkEqTransactionDeletion(transid); ddlAction.SelectedIndex = 0; } else { customerTransactionBo.DeleteEquityTransaction(transactionId); } } Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "leftpane", "loadcontrol('EquityTransactionsView','none');", true); }