Example #1
0
        public FormTransacciones()
        {
            InitializeComponent();

            _transacciones = new TransaccionesBL();
            //listaProductosBindingSource.DataSource = _productos.ObtenerProductos();
            listaTransaccionesBindingSource.DataSource = _transacciones.ObtenerTransacciones();
        }
        private void metroButton2_Click(object sender, EventArgs e)
        {
            var _transaccionesBL = new TransaccionesBL();
            var bindingSource    = new BindingSource();

            bindingSource.DataSource = _transaccionesBL.ObtenerTransacciones();

            var reporte = new ReporteFacturas();

            reporte.SetDataSource(bindingSource);
            crystalReportViewer1.ReportSource = reporte;
            crystalReportViewer1.RefreshReport();
        }
Example #3
0
        public FormGrafico()
        {
            InitializeComponent();
            var _productoBL   = new TransaccionesBL();
            var bindingSource = new BindingSource();

            bindingSource.DataSource = _productoBL.ObtenerTransacciones();

            var reporte = new GraficoReport();

            reporte.SetDataSource(bindingSource);
            crystalReportViewer1.ReportSource = reporte;
            crystalReportViewer1.RefreshReport();
        }
        private void metroButton1_Click(object sender, EventArgs e)
        {
            var fechaInicio = dateTimePicker1.Value;
            var fechaFinal  = dateTimePicker2.Value;

            var transaccionesBL = new TransaccionesBL();
            var bindingSource   = new BindingSource();

            bindingSource.DataSource = transaccionesBL
                                       .ObtenerTransacciones(fechaInicio, fechaFinal);



            var reporte = new ReporteFacturas();

            reporte.SetDataSource(bindingSource);

            crystalReportViewer1.ReportSource = reporte;
            crystalReportViewer1.RefreshReport();
        }