private void btnNuevo_Click(object sender, EventArgs e) { datCotizaciones oDatCotización = new datCotizaciones(); txtNumero.Text = oDatCotización.getIdSiguiente().ToString(); txtNumero.Enabled = false; btnConsultarPedido.Enabled = false; cmbEstado.SelectedIndex = 0; cmbEstado.Enabled = false; btnRevisarPedidos.Enabled = true; }
private void dtgCabeceraCotizacion_Click(object sender, EventArgs e) { //PRIMERO DEBEMOS DE VERIFICAR SI EXISTEN ELEMENTOS EN NUESTRO DATAGRIDVIEW if (Convert.ToInt32(DatosCabeceraCot.SelectedRowsCount) >= 1) { datCotizaciones oDatCotizacion = new datCotizaciones(); int numero = Convert.ToInt32(DatosCabeceraCot.GetFocusedRowCellValue(colNumero)); int id_empresa = Convert.ToInt32(DatosCabeceraCot.GetFocusedRowCellValue(colidEmpresa)); dtgDetalleCotizacion.DataSource = oDatCotizacion.DetalleCotizacionVista(numero, id_empresa); } }
private void btnConsultarPedido_Click(object sender, EventArgs e) { datCotizaciones oDatCotizacion = new datCotizaciones(); frmConsultaCotizacion f = new frmConsultaCotizacion(); f.ShowDialog(); txtNumero.Text = frmConsultaCotizacion.numero.ToString(); cmbEstado.SelectedIndex = frmConsultaCotizacion.estado - 1; cmbEstado.Enabled = false; dtgCotizacionDet.DataSource = oDatCotizacion.DetalleCotizacionVista(frmConsultaCotizacion.numero, frmConsultaCotizacion.id_empresa); }
private void frmConsultaCotizacion_Load(object sender, EventArgs e) { datCotizaciones oDatCotizacion = new datCotizaciones(); dtgCabeceraCotizacion.DataSource = oDatCotizacion.ConsultarCotizacionCab(frmPrincipalCompras.id_empresa); }