This is a migrated thread and some comments may be shown as answers.

MVC5 : Chart shared tool-tip title Format & programmatically add grouped legend

2 Answers 35 Views
Charts
This is a migrated thread and some comments may be shown as answers.
medialog
Top achievements
Rank 2
medialog asked on 19 Jan 2016, 10:59 AM

Hi, 

 Please find the attached image, 

1- i need to format shared tool tip  title as dd/MMM/yyyy , knowing that i was able to create a template and it works for the tool-tip but not for the title. 

 2-the legend in the attached image represents the Series lines example 2016-* And PY-* is 2016 & PY(2015), i need to pro grammatically  group them in one legend as * so when i click * it will visible OR invisible the two Series  2016-* And PY-* 

Thanks for helping.

 Regards, 

 

2 Answers, 1 is accepted

Sort by
0
Iliana Dyankova
Telerik team
answered on 21 Jan 2016, 10:03 AM
Hi Cyrille,

Up to the questions:
1- For this one you could use sharedTemplate. As an example: 
//....
.Tooltip(t=>t.Visible(true).Shared(true).SharedTemplate("#= kendo.toString(category, 'd') # <br/> Some other tooltip content "))

2- This scenario is not supported by Kendo UI Chart and in order to achieve it you need custom implementation. Providing assistance related to custom implementations is outside the scope of our support services, however I would suggest changing series.visibility via the chart.options and redrawing the chart.
// get reference to the chart widget
var chart = $("#chart").data("kendoChart");
// hide the second series
chart.options.series[1].visible = false
// redraw the chart
chart.redraw();


Regards,
Iliana Nikolova
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
medialog
Top achievements
Rank 2
answered on 22 Jan 2016, 10:06 AM

Thank you Iliana

Regards,

Tags
Charts
Asked by
medialog
Top achievements
Rank 2
Answers by
Iliana Dyankova
Telerik team
medialog
Top achievements
Rank 2
Share this question
or