Sets the Title’s text.
var chart = new CanvasJS.Chart("container", { . . title:{ text: "This is Title Text", }, . . }); chart.render();
Also See:
Comments 4
Server Side Technologies |
Front End Technologies |
Contact |
|
---|---|---|---|
ASP.NET MVC Charts | JavaScript Charts | FAQs | |
PHP Charts | jQuery Charts | Sales Enquiries | |
Spring MVC Charts | React Charts | Support Forum | |
JSP Charts | Angular Charts | Careers | |
JavaScript StockCharts | |||
Privacy Policy © fenopix
Hi Sunil,
I may not know the title for the chart ahead of time. So for example I was trying to do this;
chart.title.text = ” a dynamic title gathered from a json file or json response”;
Then of course
chart.render;
Is this possible?
Thanks,
Jim
I meant chart.render(); near the bottom not chart.render;
I answered my own question it is:
chart.options.title.text = “some new thing you want here”;
chart.render();
Assuming the chart is named chart via:
James,
I can confirm that “chart.options.title.text” is the right way to go.
We haven’t added this in documentation because it is fully not supported yet – around 95% of parameters are supported as of now. So we just need to support few more parameters before making it public.