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. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Formatting PrimaryYAxis Label Value

Thread ID:

Created:

Updated:

Platform:

Replies:

118864 Apr 17,2015 12:10 AM UTC Apr 17,2015 08:13 AM UTC ASP.NET Web Forms 1
loading
Tags: Chart
Mark Wise
Asked On April 17, 2015 12:10 AM UTC


How can I add comma formatting to the PrimaryYAxis label?

For example, I have a value "$2000", but I want it to read "$2,000".

I've tried 'MyChart.LabelFormat.PrimaryYAxis.LabelFormat = "$#,##0";'  but that throws an error.


Anyone have any ideas?

Thanks in advance!

Praveen [Syncfusion]
Replied On April 17, 2015 08:13 AM UTC

Hi Mark,

Thanks for using Syncfusion product.

We can achieve your requirement by applying/setting c0 format in “LabelFormat” of PrimaryYaxis. The 'c0' format is numbers with a currency sign, thousand separators and zero decimal places.

The following code snippet shows this,

[ASP]

LabelFormat="c0"


Screen Shot:


We have also made a sample to illustrate this. Kindly find it from the below location.


Sample:
118864.zip


Please let us know if you have any concern.

Thanks,

Praveenkumar.


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;