RadCartesianChart : Display value only when mouse hover on the legend item

2 Answers 134 Views
ChartView
minh
Top achievements
Rank 2
Iron
Iron
Iron
minh asked on 17 May 2022, 11:10 AM

Hi Telerik team,

I have a RadCartesianChart which i hided the values labels (see attached picture-1 ). I would to have a behavior like that: when mouse hover on a legend item (Cash, Time deposit, Shares, Bond... ) in the bottom of chart, the chart will display the corresponding line AND THE VALUES LABELS on the line (like you can see picture-2).

Would you please help to realize that?

 

Many thanks 

 

2 Answers, 1 is accepted

Sort by
0
Accepted
Martin Ivanov
Telerik team
answered on 20 May 2022, 07:54 AM

Hello,

One way to achieve your requirement is to use the MouseMove event of RadLegend and the IsHovered property of the LegendItem elements. If IsHovered is True, then you can show the labels for the hovered item and hide them for the other series. You can find this approach in the attached project. I hope it helps.

Regards,
Martin Ivanov
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

0
minh
Top achievements
Rank 2
Iron
Iron
Iron
answered on 24 May 2022, 02:13 AM

Hi Martin,

 

Thank you very much for your reply. Your solution work perfectly.

Many thanks again for your great support.

Minh

Tags
ChartView
Asked by
minh
Top achievements
Rank 2
Iron
Iron
Iron
Answers by
Martin Ivanov
Telerik team
minh
Top achievements
Rank 2
Iron
Iron
Iron
Share this question
or