Print Page | Close Window

hours issue

Printed From: Crystal Reports Book
Category: Crystal Reports .NET 2003
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=11259
Printed Date: 01 Apr 2025 at 9:11pm


Topic: hours issue
Posted By: Heedsie
Subject: hours issue
Date Posted: 29 Sep 2010 at 3:33am

Can anyone help me, i have multipul hours field in my database that i am getting the sum to show, but when it reaches 60minutes i want it to show as 1 hour but in crystal reports, it will keep going until 99 then go to 1.

example
 
1.15 and 1.50 would be 3hours 05 minutes but my report will show 2.65.
 
is there away i can cap it at 59 then it goes to 1hr?
 
hope this makes sense 



Replies:
Posted By: lockwelle
Date Posted: 13 Oct 2010 at 3:33am
if they are datetime fields, I would use DateAdd() with the minute function into a variable (maybe shared) and then convert it to the time you want (probably toText(variable, "hh:mm")  )...just remember to reset the variable if shared/global.
 
Hope this makes sense and isn't too late



Print Page | Close Window