Jump to content
Software FX Community

Key labels and multiple x-axes


Recommended Posts


If we want to display one x-axis label value, but have the value actually be another value from the dataset. Is that possible? Thus - on the click event I want to be able to do something like:

string companyname = chart.Series[e.Series]..AxisX.Labels[e.point]

string companyid = chart.Series[e.Series]..AxisX.KeyLabels[e.point]

I have tried using different methods, but none got me all the way: 

* I tried using KeyLabels to store the actual value and use the Label for the display. But if I add a KeyLabel it replaces the label on the x-axis and creates a lot of items in the legend that I don't want. I tried using the KeepLabels style of the datasourcesettings, and that worked, but then all the keylabels disappeared.

* I also tried creating another X-axis and create 2 Label Fieldsets and map one of them towards each x-axis. This way I could hide one of them and reach them both from the click event. However if I create another x-axis I could not figure out how to assign a field to that xaxis. Instead both fieldsets were assigned to the first x-axis which concatenated them both.

 What is the recommended way of handling key-values?

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...