Hello,
I didn t find the way by code or designer the way to display data value in each stack in my stackcolumn chart.
Please find my attachement.
Can you help me please
Hello JC,
Thank you for using our community.
When you are using the Chart Wizard, on the second step the it asks you whether you want the data values to be shown on the chart and if you select the checkbox you will achieve the desired functionality. Please take a look at the attached image.
The same can be achieved in the mark-up by adding the following code:
<ColumnChart>
<ChartText>
<igchartprop:ChartTextAppearance ChartTextFont="Arial, 7pt" ClipText="False" Column="-2" ItemFormatString="<DATA_VALUE:00.00>" Row="-2" Visible="True" />
</ChartText>
</ColumnChart>
What is more I have created a sample for you. Please take a look at it and let me know if you need further assistance.
Regards, Marina Stoyanova, Software Developer, Infragistics, Inc.
Thanks you very much, it works fine.
I fill my stackedcolumn chart with this way :
NumericSeries seriesWeek1 = new NumericSeries(); seriesWeek1.Key = "col1"; seriesWeek1.Data.DataSource = stackColumnData; seriesWeek1.Data.LabelColumn = "col1"; seriesWeek1.Data.ValueColumn = "Low"; series.Add(seriesWeek1); NumericSeries seriesWeek2 = new NumericSeries(); seriesWeek2.Key = "col3"; seriesWeek2.Data.DataSource = stackColumnData; seriesWeek2.Data.ValueColumn = "Medium"; series.Add(seriesWeek2); NumericSeries seriesWeek3 = new NumericSeries(); seriesWeek3.Key = "col4"; seriesWeek3.Data.DataSource = stackColumnData; seriesWeek3.Data.ValueColumn = "High"; series.Add(seriesWeek3);
but i didn't find the way to get in my legend group by LABEL COLUM (High,Medium,Low)
My code cs :
private void InsertCompositeChartLegends() { // Create Composite Chart Legend CompositeLegend legend = new CompositeLegend(); legend.Border.CornerRadius = 10; legend.PE.FillOpacity = 128; legend.PE.ElementType = PaintElementType.Gradient; legend.PE.FillGradientStyle = GradientStyle.ForwardDiagonal; legend.LabelStyle.Font = new Font("Times New Roman", 10); legend.ChartLayers.Add(this.UltraChart1.CompositeChart.ChartLayers.FromKey("lineLayer")); legend.ChartLayers.Add(this.UltraChart1.CompositeChart.ChartLayers.FromKey("stackColumnLayer")); legend.BoundsMeasureType = MeasureType.Percentage; legend.Bounds = new Rectangle(25, 82, 65, 14); this.UltraChart1.CompositeChart.Legends.Add(legend); }
My mark up :
<Legends> <igchartprop:CompositeLegend BoundsMeasureType="Percentage" ChartLayerList="lineLayer"> <LabelStyle Font="Microsoft Sans Serif, 7.8pt" /> </igchartprop:CompositeLegend> <igchartprop:CompositeLegend Bounds="300, 285, 300, 50" ChartLayerList="stackColumnLayer" FormatString="SERIES_LABEL" LabelStyle-HorizontalAlign="Center" LabelStyle-Orientation="Horizontal"> <LabelStyle Font="Microsoft Sans Serif, 7.8pt" /> </igchartprop:CompositeLegend> </Legends>
If you can help me please ?
I’m not sure I understand the exact values; you want to display in the legend. If the issue it that you see
<SERIES_LABEL>, just remove the string format. If you set the UltraChart1.Legend.Visible = true; The values should be the correct one. Please note that in stackcolumn chart you cannot display the column names. The legend corresponds to the whole series, meaning that you will have legend pointing out what every color from your chart means.
If this doesn’t answer your question, please isolate a sample or modify the sample I send you, so I we can be on the same page regarding the case.