Time Formating

4 posts, 0 answers
  1. ankit
    ankit avatar
    6 posts
    Member since:
    May 2011

    Posted 22 Jun 2011 Link to this post

    I have a field from the database that is an integer which is basically number of seconds.
    but i want to display it as HH:MM:SS, Is there a way to do that using expression in the reports or it has to be done in code behind.

  2. Peter
    Admin
    Peter avatar
    1652 posts

    Posted 23 Jun 2011 Link to this post

    Hello ankit,

    You can use an User Functions to convert the integer (seconds) into DateTime or correctly formatted string. For example check out the following code snippet:

    public static DateTime ConvertToDateTime(int seconds)
    {
        //TO DO convert seconds to DateTime
        return dateTime;
    }
    Greetings,
    Peter
    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
  3. Colleen
    Colleen avatar
    11 posts
    Member since:
    Jul 2019

    Posted 17 Aug in reply to Peter Link to this post

    How do you do this functionality in Telerik's stand-alone Report Designer?  Thank you
  4. Silviya
    Admin
    Silviya avatar
    388 posts

    Posted 19 Aug Link to this post

    Hello Colleen,

    To use custom functions inside the Standalone Designer it needs to be extended - check Extending Report Designer help article for reference. The designer's folder is placed in default Telerik Reporting installation folder, e.g. C:\Program Files (x86)\Progress\Telerik Reporting <VERSION>\Report Designer

    Best Regards,
    Silviya
    Progress Telerik
    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 Feedback Portal and vote to affect the priority of the items
Back to Top