Esempio n. 1
0
            internal void AddToChart(CT_ScatterChart ctScatterChart)
            {
                CT_ScatterSer scatterSer = ctScatterChart.AddNewSer();

                scatterSer.AddNewIdx().val   = (uint)this.id;
                scatterSer.AddNewOrder().val = (uint)this.order;

                CT_AxDataSource xVal = scatterSer.AddNewXVal();

                XSSFChartUtil.BuildAxDataSource <Tx>(xVal, xs);
                CT_NumDataSource yVal = scatterSer.AddNewYVal();

                XSSFChartUtil.BuildNumDataSource <Ty>(yVal, ys);

                if (IsTitleSet)
                {
                    scatterSer.tx = this.GetCTSerTx();
                }
            }
Esempio n. 2
0
            internal void AddToChart(CT_LineChart ctLineChart)
            {
                CT_LineSer  ctLineSer  = ctLineChart.AddNewSer();
                CT_Grouping ctGrouping = ctLineChart.AddNewGrouping();

                ctGrouping.val = ST_Grouping.standard;
                ctLineSer.AddNewIdx().val   = (uint)id;
                ctLineSer.AddNewOrder().val = (uint)order;

                // No marker symbol on the chart line.
                ctLineSer.AddNewMarker().AddNewSymbol().val = ST_MarkerStyle.none;

                CT_AxDataSource catDS = ctLineSer.AddNewCat();

                XSSFChartUtil.BuildAxDataSource(catDS, categories);
                CT_NumDataSource valueDS = ctLineSer.AddNewVal();

                XSSFChartUtil.BuildNumDataSource(valueDS, values);

                if (IsTitleSet)
                {
                    ctLineSer.tx = GetCTSerTx();
                }
            }