Calculating Time/Date

I have done a search on this and cannot seem to locate information.

I have two date/time fields that I need to calculate the number of hours between the two,using only business days.

My formula is:

(((ncrCompletedDate - lastacceptanceDate) / 60) / 60).

This gives me the number of hours in that range, but how do I extract out Saturday and Sunday hours? I know that @BusinessDays returns the number of days, but I need to return the hours of business days. Any suggestions?

Subject: Calculating Time/Date

Thanks for all of your help…it is working except that I had to subtract hoursPerDay in the end to get the correct number.

Subject: Calculating Time/Date

Use @BusinessDays and multiply the result with hours. Simple!

Subject: RE: Calculating Time/Date

_hoursPerDay := 8;

_dayDiff := @BusinessDays(@Date(StartTime); @Date(EndTime); 1:7) ;

_timeDiff := (@Time(EndTime) - @Time(StartTime)) / (60 * 60);

_dayDiff * _hoursPerDay + _timeDiff