# Calculation Time

## Recommended Posts

Hi Guys,

im trying to come up with a calculation which will show the amount of time a task takes.

The user will click start button and a Stop Button.

This will record the start time of the task and the ned time of the task.

Problem i have is that these tasks will be done on a 24 hour working shift. so therfore if a task starts at 23:00 and ends at 00:30...simply adding these togetehr will give a negative number.

So therfore im trying to come up with the 'best' calculation for this!

Any help would be apprciated.

##### Share on other sites

Hi Ricardo

You have to capture both the date and the time and then translate them to numbers.

Take any date in a date field and then create a calcuation field of form number equal to the date. It will who you the number of days since the year 01/01/01 I believe.

If you take a time field with a value and then create a calculation field of the form number that is that time, it will show you the number of seconds from midnight.

So you take your date as a number

x 24 hours/day

x 60 minutes/hr

x 60 seconds per minute

then add the number of seconds from midnight from the time field.

There is also a date stamp field, but I have not ahd to play with it, so I am not sure how it is expressed as a number.

The idea is to get it all in similar units so that it can be manipulated and compared.

HTH

Dave McQueen

##### Share on other sites

Hello.

Hope I well understood the matter. See the enclosure, it's a FMP8.5 file.

Click on Start then on Finish button (after some minutes otherwise result is 0). Just change manually date and time to see if finish after midnight works well for you.

If works I can give you more details.

Ciao

TimeCalc.zip

##### Share on other sites

Hello.

Hope I well understood the matter. See the enclosure, it's a FMP8.5 file.

Click on Start then on Finish button (after some minutes otherwise result is 0). Just change manually date and time to see if finish after midnight works well for you.

If works I can give you more details.

Ciao

Hi Mario,

The buttons are reversed :-) Start is finish and finish is start.

It won't calculate directly between days. See screen shot attachment.

TimeRange.zip

##### Share on other sites

Funny!

Try see this, Maybe.

Terribly late here, must go for my weekend.

Ciao

TimeCalc.zip

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×

• ### Who Viewed the Topic

1 member has viewed this topic:
vwgtiturbo
×
×
• Create New...

## Important Information

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