ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Adding symbols to XYChart line layer
Posted by KeithB on Dec-14-2024 00:50
I would like to add symbols to my lines.

I am creating an XYChart.

I add data with
LineLayer l = ChartXY.addLineLayer(dataY, colorlist[c % numcolors], names[c]);
l.setXData(dataX);

But cannot figure out how to add a symbol, it appears to only attach to Datasets, like in your example:

layer.addDataSet(data0, 0xff0000, "Quantum Computer").setDataSymbol(Chart.CircleSymbol,
                9);

  Re: Adding symbols to XYChart line layer
Posted by Peter Kwan on Dec-14-2024 14:20
Hi KeithB,

You can use Layer.getDataSet to get the first and only data set for your LineLayer. For example:

l.getDataSet(0).setDataSymbol(Chart.CircleSymbol, 9);

Best Regards
Peter Kwan

  Re: Adding symbols to XYChart line layer
Posted by KeithB on Dec-16-2024 22:32
Perfect!
Thanks!