Report with Date Range (1 Viewer)

gilescis

D. Castaldo
Local time
Today, 15:34
Joined
Jan 23, 2006
Messages
106
I have a report that prompts for date range of startdate and enddate. once ran, it takes the starttime and endtime and calculates total time per day. however if somone works on the last day of the month, it needs to only calculate the time up til midnight for that current month. Here is what I currently have:
DateDiff("n",{SchedulerPersonnelViewDetails.StartTime},{SchedulerPersonnelViewDetails.EndTime})/60

But if someone works over midnight on the last day of the month, it adds those hours to the time sheet which, anything after midnight would go on next months pay or timesheet.

Any help is greatly appreciated
:confused:
 

kevlray

Registered User.
Local time
Today, 12:34
Joined
Apr 5, 2010
Messages
1,046
I have been thinking about this. I do not have a specific formula. But I would think you should be able to create a formula and any {SchedulerPersonnelViewDetails.EndTime} that is past the end of the month (use an if statement with a datediff). Then you could subtract off any time (minutes?) past the midnight time (using datediff to get the difference).
 

gilescis

D. Castaldo
Local time
Today, 15:34
Joined
Jan 23, 2006
Messages
106
Looking for some help on this or at least some sort of example

Thanks
 

kevlray

Registered User.
Local time
Today, 12:34
Joined
Apr 5, 2010
Messages
1,046
I wish I could help you, but I am tied up with projects right now. It definately will take some time to work up a solution (if one can be found).
 

Users who are viewing this thread

Top Bottom