protected void btnAdd_Click(Object Sender, EventArgs e) { oForecast.AddBackupRetention(Int32.Parse(Request.QueryString["id"]), txtPath.Text, DateTime.Parse(txtFirst.Text), (txtRetention.Text == "" ? 0 : Int32.Parse(txtRetention.Text)), ddlRetention.SelectedItem.Value, ddlHour.SelectedItem.Value, ddlSwitch.SelectedItem.Value, ddlFrequency.SelectedItem.Value, txtFrequency.Text); Page.ClientScript.RegisterClientScriptBlock(typeof(Page), "reload", "<script type=\"text/javascript\">window.parent.div='3';window.parent.UpdateBackupUrl();<" + "/" + "script>"); }