Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 5050 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

quote:

Originally posted by digital gardener:

How can I calculate elapsed time for time sheet records? I have a field for start time and end time both setup as time fields.

Setup the following calculation defined as a time result:

Time Elapsed = End Time - Start Time

------------------

=-=-=-=-=-=-=-=-=-=-=-=-=

Kurt Knippel

Senior Filemaker Developer

http://www.inthescene.com

mailto:[email protected]

=-=-=-=-=-=-=-=-=-=-=-=-=

  • 10 years later...
Posted

Hi there

I have a similar set up to digital gardener, but I have a field called "meal break" where I enter either 30 minutes or 1 hour which deducts from the "total hours" field to reflect actual working hours.

I'm trying to devise a calculation for the "total hours" field to show: End time - Start time - Meal break.

I've tried a few variations to no avail.

Any ideas?

Many thanks

Tim

Posted

What type of field is "meal break" and what exactly do you enter into it?

Hello comment

Well at the moment the field is set up as Number and it is used to enter the duration of meal/lunch breaks which are unpaid and are usually 30 or 60 minutes. So 30 or 60 minutes will be deducted from the total hours for any given day.

Example: Tim started work at 9:00am and finished at 5:30pm but had 30 minutes for lunch. So the total hours should be 8.

Cheers

Tim

Posted

Filemaker counts time in seconds, so you cannot subtract minutes from time without converting them to seconds first. Try either =

End time - Start time - Meal break * 60


with the result type set to Time, or =




( End time - Start time - Meal break * 60 ) / 3600

with the result type set to Number (of hours).

This topic is 5050 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.