Wednesday, June 13, 2007

Calculating Time difference using Free form RPG

This is how I calculate the difference between two times in minutes...

TimeDiff = %Int(%Diff(%Time(CurTime:*Hms):%Time(OrdTime:*Hms):*mn));

where Curtime and OrdTime are numeric and *mn denotes that we need the difference in minutes to be put in the TimeDiff field.

No comments: