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

Initially empty chart

2 Answers 74 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Brett Robichaud
Top achievements
Rank 1
Brett Robichaud asked on 11 Apr 2009, 12:49 AM
I have a page with a form for options to create a chart and the chart itself on the same page. The user chooses options then clicks Generate to fill in the chart. So my problem is that when the page first renders I have it setyo to hide the chart. Then on the Generate I make it visible. The problem with the invisible approach is the LoadingPanel doesn't show up because the chart is hidden.

So I am thinking of showing the chart on first render but I need it to look nice and not show the ugly "there is no or empty series" tag in the middle, as well as showing "Chart Title" and a couple of Series names in the legend.

Is there any way to show a clean placeholder for the chart so I can utilize the loading panel when my Generate button is pressed?

2 Answers, 1 is accepted

Sort by
0
Accepted
Ves
Telerik team
answered on 13 Apr 2009, 01:54 PM
Hi Brett,

It is just a matter of appearance configuration. Here is an example of an empty RadChart:

<telerik:RadChart ID="RadChart1" runat="server"
        <Legend Visible="false"></Legend> 
        <ChartTitle Visible="false"
        </ChartTitle> 
        <PlotArea> 
            <Appearance Border-Visible="false"
                <FillStyle MainColor="White" FillType="Solid"
                </FillStyle> 
                <Border Visible="False"></Border> 
            </Appearance> 
            <EmptySeriesMessage> 
                <TextBlock Text=""
                </TextBlock> 
            </EmptySeriesMessage> 
        </PlotArea> 
    </telerik:RadChart> 


Alternatively, you can wrap the chart in a regular asp:Panel control and add an ajax setting for this panel. This will allow you to toggle the chart visibility, a similar case is described here.

Hope this helps.

Regards,
Ves
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
0
Brett Robichaud
Top achievements
Rank 1
answered on 13 Apr 2009, 02:36 PM
Ah, the panel idea is just what I was looking for. I didn't realize I could use non ajax controls as the target for a loading panel.

Thanks!
Tags
Chart (Obsolete)
Asked by
Brett Robichaud
Top achievements
Rank 1
Answers by
Ves
Telerik team
Brett Robichaud
Top achievements
Rank 1
Share this question
or