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

how to show timespan values

3 Answers 86 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
adi
Top achievements
Rank 1
adi asked on 09 Nov 2008, 06:15 PM
Hi,

I want to show timespan values in chart and datatable with format like hh:mm:ss. How can I do this?

3 Answers, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 11 Nov 2008, 05:06 PM
Hello adi,

Unfortunately, RadChart does not provide means to format the appearance of the data table content. As for the TimeSpan values -- you will need to manually update the ChartSeriesItem labels and use timespan's ToString() method to set the text of the item labels. You can find an example how to update these labels manually here.

Sincerely yours,
Ves
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
adi
Top achievements
Rank 1
answered on 11 Nov 2008, 08:26 PM
Hi Ves,

thank you for this blog entry. It's very interesting. I've tried it but the ItemDataBound event is not fired. I create the chart programmatically. I register the handler like this:

RadChart1.ItemDataBound +=

new EventHandler<ChartItemDataBoundEventArgs>(RadChart1_ItemDataBound);

But my handler will not handle anything. The RadChart documentation is not so understandable like the other controls.

Adi

 

0
Ves
Telerik team
answered on 12 Nov 2008, 12:18 PM
Hello adi,

The event fires correctly for me. Please, make sure it is wired on every postback and before DataBind method is called. If the issue remains, please, post your code. Thanks.

Sincerely,
Ves
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Chart (Obsolete)
Asked by
adi
Top achievements
Rank 1
Answers by
Ves
Telerik team
adi
Top achievements
Rank 1
Share this question
or