private void btn_nuevo_emp_Click(object sender, EventArgs e) { frm_NuevoEmpleado f = new frm_NuevoEmpleado(); f.MdiParent = this.MdiParent; f.Show(); }
private void empleadosToolStripMenuItem_Click(object sender, EventArgs e) { if (empleado_form == null) { empleado_form = new frm_NuevoEmpleado(); empleado_form.MdiParent = this; empleado_form.FormClosed += new FormClosedEventHandler(frm_NuevoEmpleado_FormClosed); empleado_form.Show(); } }
private void Form1_Load(object sender, EventArgs e) { // conexion odbc //try //{ // seguridad.Conexion.DSN = "crm"; // seguridad.Conexion.PassWord = "******"; //} //catch (Exception ex) //{ // MessageBox.Show(ex.Message); //} BloquearMDI(); Bloqueo.DesbloquearMDI(menuStrip1); //------------------------ tipo = OpBD.VerificarTipoUsuario(); if (tipo == "administrador") { //estadisticasToolStripMenuItem.Enabled = false; seguridadToolStripMenuItem.Enabled = true; foreach (ToolStripMenuItem item_seg in seguridadToolStripMenuItem.DropDownItems) { item_seg.Enabled = true; } } cal = null; con = null; neg = null; em = null; per = null; pro = null; cliente_form = null; emp = null; ini = null; empleado_form = null; caso = null; bitacora = null; ap = null; modap = null; crearu = null; edi = null; desh = null; asper = null; edper = null; elper = null; camb = null; secundarios = null; inven = null; inv_bod = null; precios = null; abono = null; balance = null; exis = null; compra = null; if (ini == null) { ini = new Form_inicio(); ini.MdiParent = this; ini.FormClosed += new FormClosedEventHandler(frm_inicio_FormClosed); ini.Show(); } }
private void frm_NuevoEmpleado_FormClosed(object sender, FormClosedEventArgs e) { empleado_form = null; }
// boton para crear un nuevo empleado private void btn_nuevo_emp_Click(object sender, EventArgs e) { frm_NuevoEmpleado empleado = new frm_NuevoEmpleado(); empleado.Show(); }