Flex Charting: Only display datatip for specific s

2019-02-13 15:29发布

问题:

I have a LineChart that contains multiple series, both LineSeries and PlotSeries, and I have a custom dataTipFunction set for the chart. However, I only want data tips displayed for line series, not the plot series. I have tried returning null from my format function, but that just displays an empty box. I have also tried disable mouse events on the plot series (by setting both mouseEnabled and mouseFocusEnabled to false), to no avail. Is this even possible?

回答1:

You can set the interactive property of a *Series to false

<mx:series>
    <mx:LineSeries yField="Profit" form="curve" displayName="Profit"/>
    <mx:LineSeries yField="Expenses" form="curve" displayName="Expenses"/>
    <mx:LineSeries yField="Amount" form="curve" displayName="Amount"/>
    <mx:PlotSeries yField="Amount" interactive="false"/>
</mx:series>


标签: flex