Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
170
Using time in grid columns
posted

Hi,

Is there any way to do the following in the UltraWebGrid

1. Have a editable column in an datagrid only accept time values like 01:30 (90 minutes) or 00:15 for 15 minutes

2. Have a summary footer that aggregates these value so if you have 2 rows with 01:30 each the total would be 03:00.

The data would need to be saved in some common unit in the database so 01:30 = 90 (minutes) or 1.5 (hours).

Thanks

Parents
No Data
Reply
  • 12004
    posted

    Hello Fredrik,

    This is just a follow up on adding a grid column using the format "HH:mm" as a DateTime data type. Enabling the footer can simply be set in the ColFootersVisibleDefault property to true. For handling calculations for total time would be to use the TimeSpan object. This can be calculated using more than one DateTime variables. Finally the column's footer can be set each time a cell is updated.

    Let me know if you have any questions with this matter. Thank you.

    Sincerely,
    Duane Hoyt
    Developer Support Engineer, MCTS
    Infragistics
    http://ko.infragistics.com/support

Children