how to make checkbox in line series chart?

Apr 16, 2012 at 6:42 AM

Dear All,

I'm New to D3 chart. I need an info.

I'm using wpf. 

My requirement need to add a checkbox in a line series chart. when the user click the checkbox the line must be visible/ not visible mode.

how can i achieve this?

please give me code sample.



Apr 18, 2012 at 5:11 AM


Any one help to solve my issue?




Apr 18, 2012 at 9:31 PM

Hello Thendral,

What you need is very simple.

First of all, the checkbox should be places in the wpf window grid, not inside the ddd control.

Then, set to true or false thethe visibility property of the linegraph in the check/uncheck event of the checkbox.  Something like this:

private void checkbox1_Checked(object sender, RoutedEventArgs e)
           plot1.LineGraph.Visibility = Visibility.Visible;         
private void checkbox1_Unchecked(object sender, RoutedEventArgs e)
            plot1.LineGraph.Visibility = Visibility.Hidden;                        

If you need me to be more explicit on how to get to the property let me know.