private void nUEVOPRODUCTOToolStripMenuItem_Click(object sender, EventArgs e) { Form frm_NuevoProducto = new Form_CargaProductos(this.NuevaEmpresa.ObtenerNumeroSiguienteProducto()); frm_NuevoProducto.Owner = this; frm_NuevoProducto.Show(); }
private void button_nuevo_Click(object sender, EventArgs e) { var padre = this.Owner as Interface_ObtenerDatos; Form NuevaFormularioProducto = new Form_CargaProductos(padre.Empresa.ObtenerNumeroSiguienteProducto(), this); NuevaFormularioProducto.Owner = this.Owner; NuevaFormularioProducto.Show(); }
private void button_modif_Click(object sender, EventArgs e) { var padre = this.Owner as Interface_GuardarCargas; var nuevo = padre.ProductoPorCodigo(dataGridView_GrillaProductos.CurrentRow.Cells["Nombre"].Value.ToString()); Form NuevaFormularioProducto = new Form_CargaProductos(nuevo); NuevaFormularioProducto.Owner = this; NuevaFormularioProducto.Show(); }
private void Form_CargaProductos_FormClosed(object sender, FormClosedEventArgs e) { if (this.CargaExitosa && !Modificar && !(Hijo is Form_GrillaProductos)) { DialogResult result = MessageBox.Show("Desea cargar otro Producto?", "Salir", MessageBoxButtons.YesNo); if (result == DialogResult.Yes) { var padre = this.Owner as Interface_ObtenerDatos; Form NuevoProducto = new Form_CargaProductos(padre.Empresa.ObtenerNumeroSiguienteCliente(), this.Owner); NuevoProducto.Owner = this.Owner; NuevoProducto.Show(); } } }