T-Square Posted December 4, 2004 Posted December 4, 2004 I need information about the behavior of global fields and their scope. 1) If more than one window is open on a particular machine, and a script running in one window changes and commits global fields, are those changes reflected in the other windows? What if the script neglects to commit? In other words, is it possible--even momentarily--for global fields to have more than one value? Assume that the tables underlying the layouts are part of the same relationship graph. 2) What is the behavior in the same circumstances above, but over a network with different network clients using globals? Thanks for any guidance. David
RalphL Posted December 4, 2004 Posted December 4, 2004 2) Gobals are local to a machine over a network. They may start with the same value but as users modifiy them they change only the values on their machine.
Ender Posted December 4, 2004 Posted December 4, 2004 1) Globals changed in one window will change in other windows too. It's the same session. If you need variables by window, you might try a multi-line global where each line is tied to a particular window name. It would need some care to build and parse this multi-line, but I think it would work.
T-Square Posted December 4, 2004 Author Posted December 4, 2004 Ralph, Ender, Thanks for the clarifications. My main concerns were, on the one hand, I DON'T want multiple globals in one session (i.e. for one user), while I DO want them across the network (i.e., for different users). Your messages make it clear that I'm in good water from that perspective. The thing I'm thinking about is that in my FM6 version of the application, I had global variables in each file--some of which overlapped. In other words, I might have a global ClientID in the Clients file, and another ClientID in the Orders file. When I went from one file to the next, I had to be sure to synchronize the values up. With my FM7 version, the globals are all still there, and I'm trying to figure out how to streamline them all into one Globals table in my interface file, so I can eliminate the redundancies as much as possible. But I wanted to be sure that any relationships I build on these new central globals would be up to date. I can't tell you how many times in the last few months I have wondered why a layout was giving me strange results, only to see that the window's context was new, and the record put on screen was not the one I expected! Thanks, David
Recommended Posts
This topic is 7363 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