public void AddRateForEquityAccount() { customeraccountvo.AccountId = Convert.ToInt16(ddlAccountNo.SelectedValue); if (ddlTransactionMode.SelectedItem.Text == "Speculative") { customeraccountvo.TransactionMode = 1; } else if (ddlTransactionMode.SelectedItem.Text == "Delivery") { customeraccountvo.TransactionMode = 0; } if (Ddl_Type.SelectedItem.Text == "Buy") { customeraccountvo.Type = "B"; } else if (Ddl_Type.SelectedItem.Text == "Sell") { customeraccountvo.Type = "S"; } else { customeraccountvo.Type = null; } if (TxtRate.Text != "") { customeraccountvo.Rate = double.Parse(TxtRate.Text); } if (Txt_SEBITrnfee.Text != "") { customeraccountvo.SebiTurnOverFee = double.Parse(Txt_SEBITrnfee.Text); } else { customeraccountvo.SebiTurnOverFee = 0.0; } if (Txt_Transcharges.Text != "") { customeraccountvo.TransactionCharges = double.Parse(Txt_Transcharges.Text); } else { customeraccountvo.TransactionCharges = 0.0; } if (Txt_stampcharges.Text != "") { customeraccountvo.StampCharges = double.Parse(Txt_stampcharges.Text); } else { customeraccountvo.StampCharges = 0.0; } if (Txt_STT.Text != "") { customeraccountvo.Stt = double.Parse(Txt_STT.Text); } else { customeraccountvo.Stt = 0.0; } if (Txt_ServiceTax.Text != "") { customeraccountvo.ServiceTax = double.Parse(Txt_ServiceTax.Text); } else { customeraccountvo.ServiceTax = 0.0; } if (chksebi.Checked == true) { customeraccountvo.IsSebiApplicableToStax = 1; } else { customeraccountvo.IsSebiApplicableToStax = 0; } if (ChkTrxn.Checked == true) { customeraccountvo.IsTrxnApplicableToStax = 1; } else { customeraccountvo.IsTrxnApplicableToStax = 0; } if (Chkstamp.Checked == true) { customeraccountvo.IsStampApplicableToStax = 1; } else { customeraccountvo.IsStampApplicableToStax = 0; } if (Chkbrk.Checked == true) { customeraccountvo.IsBrApplicableToStax = 1; } else { customeraccountvo.IsBrApplicableToStax = 0; } customeraccountvo.StartDate = Convert.ToDateTime(txtstartdate.SelectedDate); if (txtendDate.SelectedDate != DateTime.MinValue) { customeraccountvo.EndDate = Convert.ToDateTime(txtendDate.SelectedDate); } int flag = customerAccountBo.AddEquityRates(customeraccountvo); if (flag == 1) { ScriptManager.RegisterClientScriptBlock(this.Page, this.GetType(), "Message", "alert('Rates Already Added');", true); } else { ScriptManager.RegisterClientScriptBlock(this.Page, this.GetType(), "Message", "alert('Rates Added Successfully');", true); } resetcontrol(); }