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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Huge bug on ASP.NET HTML5 Charts with Fonts

Thread ID:





105761 Nov 19,2012 09:47 AM UTC Nov 19,2012 10:13 AM UTC General Discussion 2
Tags: General Discussion
Pepe Perez
Asked On November 19, 2012 09:47 AM UTC

Can't set Font size and Can't set Axis font-family.



Chart.Font.FontFamily = "Sans-Serif";

Chart.Font.Size = "15"; (Not working)


But isn't changing the size, just the font-family property is working.



SKChart.Axes["PrimaryX"].Font.FontFamily = "Sans-Serif";

SKChart.Axes["PrimaryX"].Font.Size = "15";


I get the following error:

Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error: 

Line 25:             // X.Axis Title
Line 26:             Chart.Axes["PrimaryX"].Title = "X-Axis Title Test";
Line 27:             Chart.Axes["PrimaryX"].Font.FontFamily = "Sans-Serif";
Line 28:             Chart.Axes["PrimaryX"].Font.Size = "15";
Line 29: 


Could someone provide me a help?


Thanks in advanced.

Vijayabharathi K [Syncfusion]
Replied On November 19, 2012 09:48 AM UTC

Hi Pepe Perez,


Thanks for using Syncfusion products.


1)Chart Title font


We suggest you to use below code snippet to set font size to ChartAdv control for all browser. Please refer the below code snippet to achieve this,



             //ChartAdv Font

            this.ChartAdv1.Font.Size = "35px";// Working



2)Axis Title font


We are able to reproduce the reported issue .We fixed this issue and it will be included in our VOL 4 2012 release which will available by end of October 2012. In the meantime , you can use the ChartAdv axis font property as below,



this.ChartAdv1.Axes["PrimaryX"].Font = new ChartFont("Arial", "25", ChartFontStyle.Bold);


Please let me know if any concerns.




Vijayabharathi K [Syncfusion]
Replied On November 19, 2012 10:13 AM UTC

Hi Pepe Perez,


We are glad to announce that the ChartAdv control font issue has been fixed. It available in our latest Essential studio version Vol 4 2012 and is available for download under the following link




We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.





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.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

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