示例#1
0
 private void CantidadnumericUpDown_ValueChanged(object sender, EventArgs e)
 {
     LimpiarProvider();
     if (SetError(6))
     {
         MessageBox.Show("Debe Buscar Antes de poner una cantidad");
         CantidadnumericUpDown.Value = 0;
         return;
     }
     ImportetextBox.Text = FacturacionBLL.Importedemas(CantidadnumericUpDown.Value, Convert.ToDecimal(PreciotextBox.Text)).ToString();
 }
示例#2
0
        private void IDcomboBox_SelectedIndexChanged(object sender, EventArgs e)
        {
            LimpiarProvider();
            int idfactura = Convert.ToInt32(IDcomboBox.Text);

            facturas = FacturacionBLL.Buscar(Convert.ToInt32(IDcomboBox.Text));
            CLienteIDcomboBox.Text          = facturas.ClienteID.ToString();
            DescripciponFacturatextBox.Text = facturas.Descripcion;
            DevueltatextBox.Text            = facturas.Devuelta.ToString();
            MontotextBox.Text           = facturas.Monto.ToString();
            Monto                       = facturas.Monto;
            FechadateTimePicker.Value   = facturas.Fecha;
            EfectivonumericUpDown.Value = facturas.EfectivoRecibido;
            facturas.Detalle            = FacturaDetalleBLL.GetList(x => x.FacturaId == idfactura);
            LlenarDetalleComboBox();
            DetallecomboBox.Enabled = true;
            EliminarDetalle.Enabled = true;
            foreach (var item in facturas.Detalle)
            {
                item.Importe = FacturacionBLL.Importedemas(item.Cantidad, item.Precio);
            }
            FacturadataGridView.DataSource = facturas.Detalle;
            Detalle = new List <FacturaDetalle>();
        }