示例#1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            CRVentasVendedor rpt = new CRVentasVendedor();

            rpt.Site = this.Site;
            return(rpt);
        }
示例#2
0
        private void btnReporte_Click(object sender, EventArgs e)
        {
            CRVentasVendedor    rpt = new CRVentasVendedor();
            frmRptVentxVendedor frm = new frmRptVentxVendedor();
            //rpt.SetDataSource(ds.Reporte(frmLogin.iCodSucursal, dtpFecha1.Value, dtpFecha2.Value, Convert.ToInt32(cmbFormaPago.SelectedValue),Convert.ToInt32(cmbVendedor.SelectedValue), Convert.ToInt32(cmbZona.SelectedValue)).Tables[0]);
            DataTable dt = ds.Reporte(frmLogin.iCodAlmacen, dtpFecha1.Value, dtpFecha2.Value, Convert.ToInt32(cmbFormaPago.SelectedValue), Convert.ToInt32(cmbVendedor.SelectedValue)).Tables[0];

            if (dt.Rows.Count > 0)
            {
                rpt.SetDataSource(dt);
                frm.crvRptVentxVendedor.ReportSource = rpt;
                frm.Show();
            }
        }