Quantcast
Channel: SCN : Unanswered Discussions - SAP Crystal Reports
Viewing all articles
Browse latest Browse all 4814

Display minutes as hours and minutes

$
0
0

To display minutes as hours and minutes in my report, I am using this format field formula:

 

local numbervar Hr := Truncate (CurrentFieldValue/60);

 

local numbervar Mn := Remainder (CurrentFieldValue, 60);

 

ToText (Hr,0) + ":" + ToText (Mn,0)




This formula is working great.  However, the results are 1:31 (1 hour and 31 minutes) and 1:7 (1 hour and 7 minutes).

 

Is there any way to edit the formula so 1 hour and 7 minutes shows up as 1:07?

 

Thanks for any help!


Viewing all articles
Browse latest Browse all 4814

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>