I've included code and an image below. Now for the questions. Notice that the rectangle for the legend is displaying, but not the labels. Can you see the problem in my code? My tired eyes can't. Also, the first datapoint for the line chart is NULL, but I don't want it to plot as a zero value. I tried to define the LineChart.NullHandling as "DontPlot" but that did not work. Any ideas on this one? Thanks again!
make sure you set the Label property of each series, otherwise there will be nothing to display in the legend.
also, since this is a composite chart, you need to set the NullHandling property like this:
((LineChartAppearance)lineLayer.ChartTypeAppearance).NullHandling = DontPlot
I set the Label property of the three series, but the legend only displays the labels for the two column series, not the line series. The line series is on a separate layer, if that matters. See the image below. Can the series labels be disabled from displaying under each of the columns?
When I try setting the NullHandling property as you suggested, I get the following error message: Error 1 The name 'DontPlot' does not exist in the current context
Could I be missing a reference someplace?
jmarkman said: I set the Label property of the three series, but the legend only displays the labels for the two column series, not the line series.
I set the Label property of the three series, but the legend only displays the labels for the two column series, not the line series.
i'm not sure why that would be. have you met these requirements?
- seriesLine.Label is set to something other than "Actual" (because that might be removed as a duplicate entry)
- the legend.ChartLayers collection contains the line layer
jmarkman said: Can the series labels be disabled from displaying under each of the columns?
Can the series labels be disabled from displaying under each of the columns?
yes. xAxisColumn.Labels.Visible = false; xAxisColumn.Labels.SeriesLabels.Visible = true;
jmarkman said: When I try setting the NullHandling property as you suggested, I get the following error message: Error 1 The name 'DontPlot' does not exist in the current context Could I be missing a reference someplace?
try NullHandling.DontPlot
i was able to reproduce this problem, so i logged it in our bug tracking system and fixed it. the resolution should come in a future hotfix ... sorry for the temporary inconvenience, but i don't know of any way to work around this problem... unless you want to manually draw the "moving average" legend item using a FillSceneGraph event handler.
to inquire about the status of this bug at any time, please contact Infragistics Developer Support: https://es.infragistics.com/support
the bug report # is 16449.
Almost there, and your help is greatly appreciated. In the following chart, with data for three days, the legend displays properly:
When I plot data for seven days, the "Moving Average" labels does not show:
If I increase the vertical height of the rectangle, the missing label will display. I can't figure out what causes this behavior. Is there a way to force the series labels to display horizontally within the bounds of the legend? After this one problem, I'm done.