public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            crptAccountLedgerReport rpt = new crptAccountLedgerReport();

            rpt.Site = this.Site;
            return(rpt);
        }
 public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() {
     crptAccountLedgerReport rpt = new crptAccountLedgerReport();
     rpt.Site = this.Site;
     return rpt;
 }
Пример #3
0
        /// <summary>
        ///  Function to print AccountLedgerReport in curresponding Crystal report
        /// </summary>
        /// <param name="dsAccountLedgerReport"></param>
        internal void AccountLedgerReportPrinting(DataSet dsAccountLedgerReport)
        {

            try
            {
                crptAccountLedgerReport crptAccountledgerReportObj = new crptAccountLedgerReport();
                foreach (DataTable dtbl in dsAccountLedgerReport.Tables)
                {
                    if (dtbl.TableName == "Table")
                    {
                        crptAccountledgerReportObj.Database.Tables["dtblCompanyDetails"].SetDataSource(dtbl);

                    }
                    else if (dtbl.TableName == "Table1")
                    {
                        crptAccountledgerReportObj.Database.Tables["dtblAccountLedgerReport"].SetDataSource(dtbl);

                    }

                }
                this.crptViewer.ReportSource = crptAccountledgerReportObj;

                SettingsSP spSettings = new SettingsSP();

                if (spSettings.SettingsStatusCheck("DirectPrint") == "No")
                {
                    base.Show();
                    this.BringToFront();
                }
                else
                {
                    crptAccountledgerReportObj.PrintToPrinter(1, false, 0, 0);
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show("CRV " + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }