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

Hierarchical Chart with different chart at last leaf

3 Answers 121 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Eric
Top achievements
Rank 1
Eric asked on 08 Nov 2011, 08:40 PM
I have a hierarchical chart bound to a tree of CAD assemblies. The hierarchical bar chart is working great for as many levels of assembly as I want. The problem is, when you dig down to the last leaf in any branch of the tree, the last leaf has no children, so the chart says "no data". What I'd like to do instead is show a different chart bound to the leaf instead.

Is it clear what I want to do?

does anyone have some tips on how to do this?

Eric

3 Answers, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 11 Nov 2011, 12:41 PM
Hi Eric,

I am not sure I really understand your requirement. Can you please describe a sample scenario in details so I can have a clear view on the problem. Thanks.

Best regards,
Ves
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Eric
Top achievements
Rank 1
answered on 11 Nov 2011, 06:35 PM
What I really want to do is have two charts displayed at once. Once chart is a hierarchical drill-down chart. The Root node is an assembly of mechanical parts and the bars represent the weight of each child part of the root node. (I already have this working).

I want a line chart that is bound to the same node, but displays the assembly's weight history. (A different collection in the object). 

If you drill down in the bar chart, I want the line chart to stay bound to the current node in the bar chart.

That's probably still not clear, it's hard to describe some things in words. I've created a storyboard in powerpoint and attached each slide as a jpg. Hopefully that helps clarify what I want to do.
0
Ves
Telerik team
answered on 16 Nov 2011, 02:54 PM
Hi Eric,

Please, find attached a small example, showing this. It actually uses the ItemClick event of the ChartArea to update the DataContext, thus achieving unlimited levels in the self-referencing hierarchy. Now, all you need is to create a second chart and bind it to DataContext's details.

Best regards,
Ves
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
Chart
Asked by
Eric
Top achievements
Rank 1
Answers by
Ves
Telerik team
Eric
Top achievements
Rank 1
Share this question
or