Exemplo n.º 1
0
        protected void btnDelete_Click(object sender, EventArgs e)
        {
            try
            {
                Format format = formats[ddlFormats.SelectedIndex];

                format.Delete();

                formats.Remove(format);

                Reload();

                ddlFormats_SelectedIndexChanged(sender, e);

                Session["formats"] = formats;
            }
            catch (Exception ex)
            {
                Response.Write("Error: " + ex.Message);
            }
        }