Hi,
I am using a column chart which is dynamically generated from a database. I am able to get the labels using
UltraChart1.Axis.X.Labels.ItemFormat = Infragistics.UltraChart.Shared.Styles.
AxisItemLabelFormat.ItemLabel;
I need the series label below the axis label. I tried using TitleBottom (which is not right but stop gap) but that is not working right. Here is a snapshot of the chart:
I have set SwapRowsAndColumns property to true. Please provide a resolution for this, I need it urgenty and I have been toiling with it for a very long time now... Thanks...
Regards,
Vidya
Thanks a ton Teaodor:)... I made some tweaks to the ItemFormatString property and it worked:)... Thanks once again:)...
Unfortunately, it is not possible to reorder the labels in this way. The thing you can do is combining the two labels depending on your needs:
this.ultraChart1.Axis.X.Labels.ItemFormatString = "<ITEM_LABEL> <SERIES_LABEL>";
More about this you can find:
http://help.infragistics.com/Help/NetAdvantage/NET/2008.3/CLR2.0/html/Chart_Label_Formatting.html
Thanks Teodor. I got the graph with multiple colors but my prob is the lables... If you see at the picture of the graph below, the x-axis labels are all the column2 heading and below that I am getting the first column values. What I want is the first column values to be the x-axis labels and the first column heading to be the series label.
Thanks,
You can achieve the second graph without swapping the rows and columns. You can try using:
this.ultraChart1.ColumnChart.SeriesSpacing = 0;
this.ultraChart1.ColorModel.ModelStyle = ColorModels.CustomSkin;
this.ultraChart1.ColorModel.Skin.ApplyRowWise = true;
this.ultraChart1.ColorModel.Skin.PEs.Add(new PaintElement(Color.Red));
this.ultraChart1.ColorModel.Skin.PEs.Add(new PaintElement(Color.Black));
this.ultraChart1.ColorModel.Skin.PEs.Add(new PaintElement(Color.Blue));
this.ultraChart1.ColorModel.Skin.PEs.Add(new PaintElement(Color.Yellow));
this.ultraChart1.ColorModel.Skin.PEs.Add(new PaintElement(Color.Green));
…
Basically there are 2 columns in a grid - column1 is the names and column2 is the count. What is being done for the graph is column1 should be x-axis and column2 (the count) should be y-axis. The reason I swapped rows and columns is coz we dont get the right display as you can see from the 2 graphs. What I want to see is the second graph. The problem I am having is that if you see X2 label it says Supplier Count which is the column2 (count column) header. What should appear there is Suppliers which is the column1 header. Please let me if this needs to be further expanded... Thanks... Appreciate all the time you are taking out for helping out with this one...