Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Timing in '00s of seconds

Featured Replies

  • Newbies

Hi,

I am trying to write a timing system which will allow the timekeepers to enter the times in Hours:Minutes:Seconds:Hundredths Of Seconds. It all works fine except for the "Hundredths of Seconds" part which I cannot work out how to include. Any ideas/experiences appreciated.

Thanks

Roger

Any reason you can't just use a number field to enter the hundredths? Maybe you could give us more detail about how this info will be acquired and used, and what exactly is the difficulty you're having. Do you need to add the times? Remember you can extract and assemble parts of times with the Hours(), Minutes() and Seconds() functions. They are just numbers, after all.

Roger,

Have just done the first race with a system which does just what you're asking. The time you're entering needs to be converted into seconds and hundredths of a second for any calculations. All your sorts, placings etc can be done with raw seconds. Then you need to have a calc which converts the resultant seconds back to a h:mm:ss.ss text format for display.

From your entry to seconds = hh*3600 + mm*60 + ss + .ss/100 (assumes you have four entry fields for the time groups.

To go the other way depends on how you want to display the result. Getting rid of unnecessary zeros takes the most steps. I used this calc to get the final result in a text format of hh:mm:ss.ss with leading zeroes and unnecessary ":" separators removed.

for a resultant number of seconds "Time for this lap secs"...

If(Time for this Lap secs >= 3600,TimeToText(Time for this Lap secs),If(Time for this Lap secs >= 600,Right(TimeToText(Time for this Lap secs), 5),Right(TimeToText(Time for this Lap secs), 4)))&"."&If(Int(Time for this Lap secs)=Time for this Lap secs,"00",If(Time for this Lap secs-Int(Time for this Lap secs)<.10,"0"&NumToText(Round(100*(Time for this Lap secs-Int(Time for this Lap secs)),0)),NumToText(Round(100*(Time for this Lap secs-Int(Time for this Lap secs)),0))))

This also gets around the accuracy limits where sometimes 20 hundredths of a second may come out as 0.199999999

You could also use the TimeToText function to convert whole seconds to hh:mm:ss and then add the appropriate decimal suffix text based on your hundredths. But this will not have the unnecessary zeroes and ":" trimmed.

If you want to send me a PM I can email you a couple of FMP5 examples.

Russ Baker

Canberra, Australia

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.