예제 #1
0
        private void InitializeComponent()
        {
            DevExpress.XtraReports.ReportInitializer reportInitializer = new DevExpress.XtraReports.ReportInitializer(this, "BlazorDemo.Reports.PivotGridAndChart.Report.repx");

            // Controls
            this.Detail         = reportInitializer.GetControl <DevExpress.XtraReports.UI.DetailBand>("Detail");
            this.BottomMargin   = reportInitializer.GetControl <DevExpress.XtraReports.UI.BottomMarginBand>("BottomMargin");
            this.topMarginBand1 = reportInitializer.GetControl <DevExpress.XtraReports.UI.TopMarginBand>("topMarginBand1");
            this.ReportHeader   = reportInitializer.GetControl <DevExpress.XtraReports.UI.ReportHeaderBand>("ReportHeader");
            this.xrChart        = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRChart>("xrChart");
            this.xrPivotGrid    = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPivotGrid>("xrPivotGrid");
            this.pgfSalesPerson = reportInitializer.GetPivotGridField("xrPivotGrid", "pgfSalesPerson");
            this.pgfSalesTotal  = reportInitializer.GetPivotGridField("xrPivotGrid", "pgfSalesTotal");
            this.pgfYear        = reportInitializer.GetPivotGridField("xrPivotGrid", "pgfYear");
            this.pgfQuarter     = reportInitializer.GetPivotGridField("xrPivotGrid", "pgfQuarter");
            this.xpbDevExpress  = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPictureBox>("xpbDevExpress");
            this.xpiPageCount   = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPageInfo>("xpiPageCount");
            this.xrlTitle       = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRLabel>("xrlTitle");

            // Parameters
            this.parameterViewType   = reportInitializer.GetParameter("parameterViewType");
            this.parameterShowLabels = reportInitializer.GetParameter("parameterShowLabels");
            this.parameterGenerateSeriesFromColumns = reportInitializer.GetParameter("parameterGenerateSeriesFromColumns");
            this.parameterShowRowGrandTotals        = reportInitializer.GetParameter("parameterShowRowGrandTotals");
            this.parameterShowColumnGrandTotals     = reportInitializer.GetParameter("parameterShowColumnGrandTotals");

            // Data Sources
            this.sqlDataSource1 = reportInitializer.GetDataSource <DevExpress.DataAccess.Sql.SqlDataSource>("sqlDataSource1");

            // Styles
            this.OddStyle      = reportInitializer.GetStyle("OddStyle");
            this.GroupHeader   = reportInitializer.GetStyle("GroupHeader");
            this.EvenStyle     = reportInitializer.GetStyle("EvenStyle");
            this.CategoryStyle = reportInitializer.GetStyle("CategoryStyle");
        }
        private void InitializeComponent()
        {
            DevExpress.XtraReports.ReportInitializer reportInitializer = new DevExpress.XtraReports.ReportInitializer(this, "AspNetCoreDemos.Reporting.Reports.PivotGrid.Report.repx");

            // Controls
            this.Detail             = reportInitializer.GetControl <DevExpress.XtraReports.UI.DetailBand>("Detail");
            this.ReportHeader       = reportInitializer.GetControl <DevExpress.XtraReports.UI.ReportHeaderBand>("ReportHeader");
            this.BottomMargin       = reportInitializer.GetControl <DevExpress.XtraReports.UI.BottomMarginBand>("BottomMargin");
            this.topMarginBand1     = reportInitializer.GetControl <DevExpress.XtraReports.UI.TopMarginBand>("topMarginBand1");
            this.xrPivotGrid1       = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPivotGrid>("xrPivotGrid1");
            this.fieldCountry       = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldCountry");
            this.fieldSalesPerson   = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldSalesPerson");
            this.fieldYear          = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldYear");
            this.fieldQuarter       = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldQuarter");
            this.fieldExtendedPrice = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldExtendedPrice");
            this.fieldQuantity      = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldQuantity");
            this.fieldProductName   = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldProductName");
            this.fieldCategoryName  = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldCategoryName");
            this.fieldOrderID       = reportInitializer.GetPivotGridField("xrPivotGrid1", "fieldOrderID");
            this.xrPictureBox1      = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPictureBox>("xrPictureBox1");
            this.xrPageInfo1        = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRPageInfo>("xrPageInfo1");
            this.xrLabel2           = reportInitializer.GetControl <DevExpress.XtraReports.UI.XRLabel>("xrLabel2");

            // Data Sources
            this.sqlDataSource1 = reportInitializer.GetDataSource <DevExpress.DataAccess.Sql.SqlDataSource>("sqlDataSource1");

            // Styles
            this.xrPivotGridCellStyle  = reportInitializer.GetStyle("xrPivotGridCellStyle");
            this.xrPivotGridFieldStyle = reportInitializer.GetStyle("xrPivotGridFieldStyle");
        }