Exemple #1
0
        ChartBase RunChartBuild(Report rpt, Row row)
        {
            // Get the matrix that defines the data;
            _ChartMatrix.SetMyData(rpt, GetMyData(rpt));                // set the data in the matrix
            int maxColumns;
            int maxRows;

            MatrixCellEntry[,] matrix = _ChartMatrix.RunBuild(rpt, out maxRows, out maxColumns);

            // Build the Chart bitmap, along with data regions
            ChartBase cb = null;

            switch (_Type)
            {
            case ChartTypeEnum.Column:
                cb = new ChartColumn(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Line:
            case ChartTypeEnum.Area:                                            // handled by line
                cb = new ChartLine(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Bar:
                cb = new ChartBar(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Pie:
            case ChartTypeEnum.Doughnut:                                // handled by pie
                cb = new ChartPie(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Bubble:
            case ChartTypeEnum.Scatter:
                cb = new ChartBubble(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Map:
                cb = new ChartMap(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;

            case ChartTypeEnum.Stock:
            default:
                cb = new ChartColumn(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                break;
            }

            return(cb);
        }
Exemple #2
0
        ChartBase RunChartBuild(Report rpt, Row row)
        {
            // Get the matrix that defines the data;
            _ChartMatrix.SetMyData(rpt, GetMyData(rpt));	// set the data in the matrix
            int maxColumns;
            int maxRows;
            MatrixCellEntry[,] matrix = _ChartMatrix.RunBuild(rpt, out maxRows, out maxColumns);

            // Build the Chart bitmap, along with data regions
            ChartBase cb=null;
            switch (_Type)
            {
                case ChartTypeEnum.Column:
                    cb = new ChartColumn(rpt, row, this, matrix,_showTooltips,_showTooltipsX,_ToolTipYFormat,_ToolTipXFormat);
                    break;
                case ChartTypeEnum.Line:
                case ChartTypeEnum.Area:			// handled by line
                    cb = new ChartLine(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
                case ChartTypeEnum.Bar:
                    cb = new ChartBar(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
                case ChartTypeEnum.Pie:
                case ChartTypeEnum.Doughnut:		// handled by pie
                    cb = new ChartPie(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
                case ChartTypeEnum.Bubble:
                case ChartTypeEnum.Scatter:
                    cb = new ChartBubble(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
                case ChartTypeEnum.Map:
                    cb = new ChartMap(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
                case ChartTypeEnum.Stock:
                default:
                    cb = new ChartColumn(rpt, row, this, matrix, _showTooltips, _showTooltipsX, _ToolTipYFormat, _ToolTipXFormat);
                    break;
            }

            return cb;
        }