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

'Saving' a global value?

Featured Replies

I'd like my shared solution to remember the value of a particular global, even after the files are closed and re-opened. The value is a moving target--it constantly gets updated. Is it possible in FM7 or 8? Or, any suggested workarounds? Thanks much.

For a hosted solution, globals won't retain any changes that a connected client makes. You can always initialize them with an opening script. If you want to remember values from session to session, then the values must be stored as data in a record.

For retaining a value for all users, you could use a file with one record containing the fields to be remembered (or a record for each field-value pair). Then set and retrieve values from this file as necessary. However, in multi-user situations it could be problematic to have each user set these values as they log out, especially with record locking.

If you want each user to retain their own values, then use a record in a User or Employee file to store those values.

Same deal in FM7/8 by the way; but it's a little easier to define and relate to these special-purpose tables.

Edited by Guest

Hi,

Ender is correct!

One other way is to take the file in question offline, undo file sharing and open as a single user non-hosted file. Set your global field, close the file. Open again, turn sharing back on, place in the server hosted folder and the file will automatically remember the last global value from when it was opened as a single user file.

HTH

Tim

Ender is correct!

Hey, you say that like it's a surprise. What's up with that? Have I EVER been wrong?

:king:

Ok, so there was that one time a couple years ago when I told you buy Dell and sell Apple, but you can't hold that against me forever! Dell will bounce back .

Hey no suprise, good advice from a well respected all around good guy. I am always interested in reading your responses.

Just giving props.

I have always liked Dell. I've been running two of their server machines without any down time for 5+ years now.

Tim

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.