Пример #1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            CRUtilidad3 rpt = new CRUtilidad3();

            rpt.Site = this.Site;
            return(rpt);
        }
Пример #2
0
 private void btnReporte_Click(object sender, EventArgs e)
 {
     try
     {
         CRUtilidad3         rpt = new CRUtilidad3();
         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.Utilidad3(dtpFecha1.Value, dtpFecha2.Value, frmLogin.iCodAlmacen).Tables[0];
         if (dt.Rows.Count > 0)
         {
             rpt.SetDataSource(dt);
             frm.crvRptVentxVendedor.ReportSource = rpt;
             frm.Show();
         }
     }
     catch (Exception a) { MessageBox.Show(a.Message); }
 }