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

{Help Request} RadChart + RadGrid / Selected Index

1 Answer 49 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Robert
Top achievements
Rank 1
Robert asked on 11 Jun 2012, 12:52 AM
I have a RadChart and RadGrid populated with items. (The Datasources are different due to the returned data but they have the same DataKey values)

How can I quickly allow the user to select any of the items on the Radchart and make that the SelectedRow for the RadGrid? (the items will share the same DataKey value) 

I want them to be able to click the bar chart item and then have the corresponding record highlighted on the Radgrid below the chart.

I tried attaching an event handler for the Click events which seems to create event behavior I would expect, but I am having trouble linking these two controls together in the manner I would like.  I believe there would be a quick clientside solution for this so I can simply get a reference to the RadGrid, find the row with a DataKey value that matches the one that it was called from, and make that the SelectedRow so it will be highlighted to the user.  Sounds good in theory but I am having trouble with implementation of such a scenario.

Any help is appreciated

1 Answer, 1 is accepted

Sort by
0
Petar Marchev
Telerik team
answered on 13 Jun 2012, 12:01 PM
Hello John,

It is not possible to link the RadChart and RadGrid with out-of-the-box means. However, with some java script I think you will be able to do it. I have attached a simple project to demonstrate one approach you can use. Do examine it and see if you can adapt this to your current project.

All the best,
Petar Marchev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Chart (Obsolete)
Asked by
Robert
Top achievements
Rank 1
Answers by
Petar Marchev
Telerik team
Share this question
or