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

YValue with duration (TimeSpan)

1 Answer 24 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Benedict
Top achievements
Rank 1
Benedict asked on 16 Mar 2010, 10:01 AM
Hello,

I intend to display a duration per XCategory, so I bound the YValue DataPointMember to a TimeSpan. I got an exception then. If I do bind to double value, everything works fine.

What should I do here ? I want to have a good formating on the bar and y-axis here (e.g. 2 Minutes, 1 hour, or 00:11:00).

Thanking you in anticipation

1 Answer, 1 is accepted

Sort by
0
Velin
Telerik team
answered on 18 Mar 2010, 05:15 PM
Hello Benedict,

Unfortunately, what you have tried to do is not supported by the control. To achieve similar functionality you will need to convert the TimeSpan duration to a meaningful double representation(e.g TimeSpan.TotalSeconds) and set each bar label content to the correct string.

Sincerely yours,
Velin
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.
Tags
Chart
Asked by
Benedict
Top achievements
Rank 1
Answers by
Velin
Telerik team
Share this question
or