Skip 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.

realtime viewing of counting seconds

Featured Replies

I was wondering as part of my attempt to make a real-time filemaker clock to count usage time...how do I view the real time ticking?? I can see the beginning and end of this concept script I have...but I have NO IDEA how to see it as it's counting. Here's my concept script:

Set Field["counter", "0"]

Loop

Set Field["counter","counter+1"]

Exit Loop If["counter=50"]

End Loop

Anyone have any suggestions???

You could create a script:

code:


Loop

SetField [TimeField, Status(CurrentTime)]

Pause/Resume ["0:00:01"]

End Loop

The problem is, it'll interfere with other scripts.

A better way to count user time is to create "SignIn", "SignOut" and "TimeOpen" fields, and have the SignIn field set to the current time when you open the file, then the SignOut field set to the current time and set the TimeOpen field to the difference when you close the file. You won't get a realtime readout, but it's usable.

I use a technique for this, but only to test the general speed of scripts. It can help to see what steps are faster or slower.

The system uses 3 Global fields TIMESTART & TIMESTOP & TIMETOT, and is simply inserted into a looping script: e.g.

START SCRIPT

Go to layout “Timer”

SetField(TIMESTART)

Status(CurrentTime)

Loop

<Here comes your script>

Exit Loop / Or go to next exit after last etc.

SetField (TIMESTOP)

Status(CurrentTime)

SetField (TIMETOT)

abs(TIMESTART - TIMESTOP)

NB: If you add the last command:

SetField (TIMETOT)

abs(TIMESTART - TIMESTOP)

Into the loop, the seconds will tick away as the script performs, but remember this will slow down your script.

Hope this helps a bit

Rigsby

  • Author

Thanks you guys for replying to my question and for your help. It's pretty hard to run this, as was stated "it will interfere with other scripts". I have scripts all over the place in my web based sign-in program that run at various times and simultaneously so this idea is too resource intensive. I'll just try a simple script that calculates the time difference between now and when someone clocks in. Afterall, it's on the web and it's static for 5 seconds until it refreshes itself. Thanks again!

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.