I am trying to get decimals to show for certain chart data, but not for others. The user can choose a measure to chart from a select list. For example, a dollar amount would not need two decimals. But if they pick a percentage, it needs to have two decimals. In the attached screen shot, you can see that decimals are not necessary.
However, in the next screen shot, you can see how I need decimal places:
Since this is a legacy AnyChart, I'm looking at the XML code window to see if I can maybe do an if... then statement of some kind? Possibly in this section:
<format><![CDATA[{%Name}{enabled:False} - {%Value}{numDecimals:2,decimalSeparator:.,thousandsSeparator:\,}]]></format>
But I may be doing this the hard way. I tried to make my chart a multi-series chart but only one series would show at a time. I had to make it a Legacy AnyChart to get more than one series to show. So, this is two parter: Can I do an if...then... statement in XML? Or, how do I get more than one series to show at a time in a "multi-series" chart? I need it to look like the first picture above. Thank you!
I'd go with two charts (or more, if necessary): one would display dollars, another one percentage.
format each region the way you want (with decimals, without them, whatever)
set the select list item to submit the page
create server-side condition for each chart region; for example, a function body for the 1st region:
return :P1_SELECT_LIST := 'dollars';
Initially, when you enter the page, select list item won't have any value so none of chart region will be displayed. Then, as you select something and submit the page, server-side condition for one of regions will be satisfied and that region will be displayed. If you select something else, another region will be displayed and other(s) won't.