private void altaAutomovil_click(object sender, EventArgs e) { if (noPuedeIngresar(1)) { return; } if (ActiveMdiChild != null) { ActiveMdiChild.Close(); } Abm_Automovil.AltaAutomovil altaAutomovil = new Abm_Automovil.AltaAutomovil(); altaAutomovil.mostrar(this); }
protected void botonModificacion_Click_1(object sender, EventArgs e) { if (tablaListado.SelectedRows.Count == 1) { int index = tablaListado.SelectedRows[0].Index; AutomovilDTO automovil = (AutomovilDTO)automoviles.ElementAt(index); AltaAutomovil crearAutomovilForm = new AltaAutomovil(automovil, this); crearAutomovilForm.ShowDialog(); } else { MessageBox.Show("Debe seleccionar el automovil a modificar"); } }
protected void botonAlta_Click_1(object sender, EventArgs e) { AltaAutomovil altaAutomovilForm = new AltaAutomovil(this); altaAutomovilForm.ShowDialog(); }