Beispiel #1
0
        public ChartDataPointInstance AddCell(ReportProcessing.ProcessingContext pc, int currCellDPIndex)
        {
            ChartDataPointInstancesList dataPoints = this.CurrentMultiChart.DataPoints;
            Chart chart = (Chart)base.m_reportItemDef;
            int   num   = (currCellDPIndex < 0) ? this.GetCurrentCellDPIndex() : currCellDPIndex;
            ChartDataPointInstance chartDataPointInstance = new ChartDataPointInstance(pc, chart, this.GetCellDataPoint(num), num);

            if (chart.ProcessingInnerGrouping == Pivot.ProcessingInnerGroupings.Column)
            {
                dataPoints[this.m_currentCellOuterIndex].Add(chartDataPointInstance);
            }
            else
            {
                if (this.m_currentCellOuterIndex == 0)
                {
                    Global.Tracer.Assert(dataPoints.Count == this.m_currentCellInnerIndex);
                    ChartDataPointInstanceList value = new ChartDataPointInstanceList();
                    dataPoints.Add(value);
                }
                dataPoints[this.m_currentCellInnerIndex].Add(chartDataPointInstance);
            }
            this.m_currentCellInnerIndex++;
            return(chartDataPointInstance);
        }
Beispiel #2
0
        public ChartDataPointInstanceInfo(ReportProcessing.ProcessingContext pc, Chart chart, ChartDataPoint dataPointDef, int dataPointIndex, ChartDataPointInstance owner)
        {
            this.m_dataPointIndex = dataPointIndex;
            int count = dataPointDef.DataValues.Count;

            this.m_dataValues = new object[count];
            bool flag = false;

            if (dataPointDef.Action != null)
            {
                flag = dataPointDef.Action.ResetObjectModelForDrillthroughContext(pc.ReportObjectModel, dataPointDef);
            }
            for (int i = 0; i < count; i++)
            {
                this.m_dataValues[i] = pc.ReportRuntime.EvaluateChartDataPointDataValueExpression(dataPointDef, dataPointDef.DataValues[i], chart.Name);
            }
            if (flag)
            {
                dataPointDef.Action.GetSelectedItemsForDrillthroughContext(pc.ReportObjectModel, dataPointDef);
            }
            if (dataPointDef.DataLabel != null)
            {
                this.m_dataLabelStyleAttributeValues = Chart.CreateStyle(pc, dataPointDef.DataLabel.StyleClass, chart.Name + ".DataLabel", owner.UniqueName);
                this.m_dataLabelValue = pc.ReportRuntime.EvaluateChartDataLabelValueExpression(dataPointDef, chart.Name, this.m_dataLabelStyleAttributeValues);
            }
            if (dataPointDef.Action != null)
            {
                this.m_action = ReportProcessing.RuntimeRICollection.CreateActionInstance(pc, dataPointDef, owner.UniqueName, chart.ObjectType, chart.Name + ".DataPoint");
            }
            this.m_styleAttributeValues = Chart.CreateStyle(pc, dataPointDef.StyleClass, chart.Name + ".DataPoint", owner.UniqueName);
            if (dataPointDef.MarkerStyleClass != null)
            {
                this.m_markerStyleAttributeValues = Chart.CreateStyle(pc, dataPointDef.MarkerStyleClass, chart.Name + ".DataPoint.Marker", owner.UniqueName);
            }
            if (dataPointDef.CustomProperties != null)
            {
                this.m_customPropertyInstances = dataPointDef.CustomProperties.EvaluateExpressions(chart.ObjectType, chart.Name, "DataPoint(" + (dataPointIndex + 1).ToString(CultureInfo.InvariantCulture) + ").", pc);
            }
            pc.ChunkManager.AddInstance(this, owner, pc.InPageSection);
        }