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

Make a chart not visible in codebehind

2 Answers 53 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Nadine
Top achievements
Rank 1
Nadine asked on 30 Apr 2011, 12:14 AM
Is there a property that makes the chart not visible in code behind. I've looked at the framework for the chart component and it looks like it will accept "hidden" or "collapsed", but they don't seem to work.

2 Answers, 1 is accepted

Sort by
0
Accepted
Tsvetie
Telerik team
answered on 04 May 2011, 12:38 PM
Hello Nadine,
You can use the Visibility property of RadChart to do this. For example:
<Button x:Name="Button1" Click="Button1_Click" Width="100" Height="100">Hide chart</Button>
<telerik:RadChart x:Name="RadChart1"></telerik:RadChart>

private void Button1_Click(object sender, RoutedEventArgs e)
{
    if (RadChart1.Visibility == System.Windows.Visibility.Visible)
        RadChart1.Visibility = System.Windows.Visibility.Collapsed;
    else
        RadChart1.Visibility = System.Windows.Visibility.Visible;
}

Greetings,
Tsvetie
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Nadine
Top achievements
Rank 1
answered on 05 May 2011, 12:03 AM
That worked great. Thanks.
Tags
Chart
Asked by
Nadine
Top achievements
Rank 1
Answers by
Tsvetie
Telerik team
Nadine
Top achievements
Rank 1
Share this question
or