Ejemplo n.º 1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            crptBalanceSheet rpt = new crptBalanceSheet();

            rpt.Site = this.Site;
            return(rpt);
        }
 public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() {
     crptBalanceSheet rpt = new crptBalanceSheet();
     rpt.Site = this.Site;
     return rpt;
 }
Ejemplo n.º 3
0
        /// <summary>
        ///  Function to print  BalanceSheetReport in curresponding Crystal report
        /// </summary>
        /// <param name="dsAgeing"></param>
        internal void BalanceSheetReportPrint(DataSet dsAgeing)
        {
            try
            {
                crptBalanceSheet crptBalanceSheet = new crptBalanceSheet();

                foreach (DataTable dtbl in dsAgeing.Tables)
                {
                    if (dtbl.TableName == "Table1")
                    {
                        crptBalanceSheet.Database.Tables["dtblBalanceSheet"].SetDataSource(dtbl);
                    }
                    else if (dtbl.TableName == "Table2")
                    {
                        crptBalanceSheet.Database.Tables["dtblCompanyReport1"].SetDataSource(dtbl);
                    }

                }
                this.crptViewer.ReportSource = crptBalanceSheet;

                SettingsSP spSettings = new SettingsSP();
                if (spSettings.SettingsStatusCheck("DirectPrint") == "No")
                {
                    base.Show();
                    this.BringToFront();
                }
                else
                {
                    crptBalanceSheet.PrintToPrinter(1, false, 0, 0);
                }
            }
            catch (Exception ex)
            {

                MessageBox.Show("BS14:" + ex.Message, "OpenMiracle", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }