private void MNUEVO_Click(object sender, EventArgs e) { frmrol frm = new frmrol(); frm._evento = "NUEVO"; frm.ShowDialog(); Listar(); }
private void MMODIFICAR_Click(object sender, EventArgs e) { frmrol frm = new frmrol(); frm.ObtenerRegistro(dataGridView1.CurrentRow.Cells[0].Value.ToString()); frm._evento = "MODIFICAR"; frm.idusuario_ = dataGridView1.CurrentRow.Cells[0].Value.ToString(); frm.ShowDialog(); Listar(); }
private void MHABILITAR_Click(object sender, EventArgs e) { frmrol frm = new frmrol(); frm.idusuario_ = dataGridView1.CurrentRow.Cells[0].Value.ToString(); frm.ObtenerRegistro(dataGridView1.CurrentRow.Cells[0].Value.ToString()); if (dataGridView1.CurrentRow.Cells[2].Value.ToString() == "HABILITADO") { frm._evento = "HABILITAR"; } else { frm._evento = "DESHABILITAR"; } frm.TXTNOMBRE.ReadOnly = true; frm.ShowDialog(); Listar(); }