We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Bar Chart cannot sort in original order?

Horizontal bar chart is a little bit odd, because it has X and Y axes reversed. 

Now I have four horizontal bars need to display: 
  • 3 and 4 years old
  • 5 and 6 years old
  • 7 to 13 years old
  • 14 to 17 years old
When the four bars are put on the axis, they are sorted into:
  • 14 to 17 years old
  • 3 and 4 years old
  • 5 and 6 years old
  • 7 to 13 years old
Apparently it is because "1" is sorted ahead of other numbers.

There is "Indexed" may put the categories in original order, but it only works on X axis, but in bar chart the category is on Y axis. So it does not work for bar chart.

Is there anyway I can show the bars in the original order of the points of the bar series?

Thanks!


2 Replies

FJ Feng Jiang July 31, 2019 08:35 PM UTC

OK. I just fixed this with "Customizing Label Text".


BP Baby Palanidurai Syncfusion Team August 1, 2019 06:11 AM UTC

Hi Feng, 


Most welcome. Kindly revert us, if you need any further assistance on this. We are always happy in assisting you. 


Thanks, 
Baby. 


Loader.
Live Chat Icon For mobile
Up arrow icon