protected void btnUpdate_Click(object sender, EventArgs e)
        {
            textName.Enabled    = true;
            textCountry.Enabled = true;
            textCity.Enabled    = true;

            string valor  = ddlEditorial.SelectedValue;
            int    valor2 = ddlEditorial.SelectedIndex + 1;

            foreach (EntClsEditorial edit in lstEditorial)
            {
                if (Convert.ToString(edit.Id) == valor)
                {
                    ent_edit = edit;
                }
            }
            bsn_edit.updateEditorial(valor2, textName.Text, textCountry.Text, textCity.Text);
            //loadDrop();
            //clear();
        }
Ejemplo n.º 2
0
 protected void btnUpdate_Click(object sender, EventArgs e)
 {
     try {
         string valor  = ddlEditorial.SelectedValue;
         int    valor2 = ddlEditorial.SelectedIndex + 1;
         foreach (EntClsEditorial edit in lstEditorial)
         {
             if (Convert.ToString(edit.Id) == valor)
             {
                 ent_edit = edit;
             }
         }
         bsn_edit.updateEditorial(valor2, textName.Text, textCountry.Text, textCity.Text);
         SucceUpdateEdit();
         listAdd();
     }
     catch
     {
         errorUpdateEdit();
     }
 }