Genx Posted October 1, 2005 Posted October 1, 2005 Righto, im hosting a file on fm server 7, lots of globals which need to be set at startup... my question is, when im using the set field script step, do i have to be in the layout related to the field? Secondly, is there a quicker way of doing this.
Himitsu Posted October 1, 2005 Posted October 1, 2005 Well, in all of my solutions I had to set it to the layout that is contained in that table. A quicker way of doing this is to make a table with all the globals, kind of like a settings table containing only one record. Then make a relationship that shows everything. That is one way, but without knowing more details of what your set up looks like, it would be hard to give a better way.
IdealData Posted October 1, 2005 Posted October 1, 2005 The "Set Field" step DOES NOT require the layout with the field on it. As the files are hosted on FMS then globals are "remembered" at there last content when the file was last opened/closed in FMP (not through a host). If you're the developer then close the files and quit FMS. Open the files individually in FMP and set the globals. Close the file. Repeat for each file. Reopen in FMS. The globals are now "fixed". Alternatively, execute a script to initialise the globals when the file is first opened by the user(s). You get more flexibility this way as you change the initial state of the globals without shutting FMS down.
Genx Posted October 1, 2005 Author Posted October 1, 2005 so your saying that if i close down the server file... load it up on fmp, set all the globals manually then relaunch it on server, all the users will now have the current globals?
Slobey Posted October 4, 2005 Posted October 4, 2005 To set the globals you do not need to be in a layout containing the field. But globals are local, meaning that every user has their own set of globals, the server can't set them. So you may need to make the startup script launch from each users PC.
Genx Posted October 5, 2005 Author Posted October 5, 2005 Then why are the globals i set, prior to hosting the file on server all still there?
mr_vodka Posted October 5, 2005 Posted October 5, 2005 Global fields will retain their values of the host file. Any other remote users will have their own set of global values set by the host file. In other words, if you have a global value set in the host file, every time a user connects to it, you will see the value of the host file. This can be usefule to store such values as your company name or images, etc. But not for stuff as username etc. Those should be set with a script and be an empty value in your original file. David Kachel had a pretty good white paper for beginners. Take a look at the thread here. White Paper
Recommended Posts
This topic is 6988 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 accountSign in
Already have an account? Sign in here.
Sign In Now