Jump to content
Software FX Community

Bar Graph x-axis text to legend? only 1 series


Recommended Posts


 The result set used for my bar graph only produces 1 series. But I want each value on the x-axis to be represented in the legend instead of being all grouped under the name of series 0. Is there a way to do this?

For example, my query returns

 FruitGroup Count------------- --------- Apples   10Grapes   2


But instead of "Apples" and "Grapes" showing up in legend box,  I only get "FruitGroup", with both Apples and Graphes represented in the same color in the graph (I know I can use Multiple Colors option to fix this part).



Link to comment
Share on other sites

Whenever you set MultipleColors to true, the legendbox displays the Axis X Labels. So I think you get the desired effects just by doing that.

DataTable table1 = new DataTable("Test");


"FruitGroup", System.Type.GetType("System.String"));table1.Columns.Add("Count", System.Type.GetType("System.Double"));


new object[] { "Apples", 10 });table1.Rows.Add(new object[] { "Grapes", 2 });


new FieldMap("FruitGroup", FieldUsage.Label));chart1.DataSourceSettings.Fields.Add(new FieldMap("Count", FieldUsage.Value));

chart1.DataSource = table1;

chart1.Gallery =

chart1.AllSeries.MultipleColors =




Andre G

Link to comment
Share on other sites

  • 8 months later...

 The thread you linked to is for Chart FX for Client Server 5.1. This thread is for Chart FX for Reporting Services. I am assuming you want the solution for Client Server, since there is no API in Chart FX for Reporting Services. I will reply on the correct forum.

Link to comment
Share on other sites

  • 3 years later...

Hi Andre,

I also wnat help in my another issue.

In my application(Same Chart) I am using Series 0 as Bar chart and Series 1 For Line Chart.

but problem is my points of line charts (i.e. values) gets hidden by Bar chart means it goes behind the Bar Chart.

and if I add the line Series[0].SendToBack() then the tooltip of the Bars show wierd data (i.e tooltip shows PC instead of showing %)

Plz reply fast if possible as I need urgent help on this.

Thanking u in Advance.



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...