In answer to part 2 . . . in the inspector you can set if a field can be entered into for either browse mode or find mode. If you uncheck the browse mode they can not enter the field in browse mode and therefore can not make changes. One down side of doing that is if you have an edit text box with a vertical scroll bar they can not entered into the field to scroll it.
This is great! Thanks!
I had made a script to revert any changes, but that was a bit annoying for the users because they could get tricked into thinking that he could make changes... only to find out that their changes were not saved. This is much better.
Do you have any suggestions on how I can debug my modal window script?
Error 3 means "command unavailable". Show / Hide Menu Bar is not available for Desktop.
Check compatibility of your script steps.
"Your access privileges do not allow..."
Check your access privileges for the tables, layouts and scripts.
Check for script triggers that want to do something outside of the allowed scope.
You can disable access to fields on a layout by unchecking "Browse Mode" in inspector Data > Field Entry.
Thank you for your response. What would be a better script for the modal window? Do you mind walking me through the steps or indicating a good site that has them?
I'm getting Erro 3 on just about 90% of the steps. I'm not sure why. Does this mean that filemaker doesn't support modal windows?
You might also check to make sure you have the script itself set to run with full access privileges.
If the script itself is allowed for execution in that privilege set than it should not be a problem.
A better script without access is still worthless, this one isn't that far from OK.
Don't fancy the "Pause", clicking outside the fields will call for a commit so you might wanna think about that.
Reviewing the priv set would be the first thing to check. No?
keywords and election:
You're brilliant. Thanks.
So, I checked the priv set and the users were not able to run the scripts. Then, I allowed them to run the scripts, but now, when I click on the "Edit" button, I get this message: "This record cannot be modified in this window because it is already being modified in a different window." if I'm logged in as the user. Strangely enough, it works fine if I'm the Admin.
What could be going wrong?
Aside from some weird bug it seems the record is still open.
You could try putting a Commit Record on top of the script.
Because you're opening the same record in another window and you can only edit it in one place.
The open state is tied to the window.
Thank you! This is awesome. Totally solved the problem.
Side note: instead of putting "Commit Record" on top of the script, I put "Revert Record." Because "Commit Record" was overwriting my commands to cancel any changes if the user clicks the "CANCEL" button. It was making towards all changes were saved regardless. But the "Revert Record" on top of the script solved everything.
Now, users can edit the fields, save the changes and cancel them if they wish.
Thank you all so much for your help!