private void btn_clave_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e) { try { var miForma = new Ayudas.Form_user_admin(); miForma.Owner = this; miForma.PasaDatos = RecibePermiso; miForma.ShowDialog(); } catch (Exception ex) { MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } }
private void btn_clave_Click(object sender, EventArgs e) { try { var miForma = new Ayudas.Form_user_admin(); miForma.Owner = this; miForma.PasaDatos = RecibePermiso; var sw = false; sw = Convert.ToBoolean (miForma.ShowDialog()); if (sw) { btn_detanadir.Enabled = true; } else { btn_detanadir.Enabled = false; } } catch (Exception ex) { MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } }