Jump to content

Locking records


dcecil

This topic is 8299 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I am creating an online form that around 10 people will have access to. They will have the option of creating and editing records which is no problem. The problem is, I would like it to where one person could not make changes to the other person's record, at all. Is this possible? I think I've tried every combination of options in the password/access/groups windows.

Thanks,

Link to comment
Share on other sites

  • 3 weeks later...

Here is a possible solution that assumes all users have their own computers:

If you do not already have one, create a text field called Creator_Name.

Creator_Name must be back-filled with the user name (as specified in Edit Menu, Preferences, Application) of the person who created the record. When a user creates a new record, this field must automatically be filled with status( currentusername ).

Create a calculated text field called Record_Lock:

Record_Lock = Case (Creator_Name = status( currentusername ), "", "X" )

If the person accessing the record is using the same name as the record creator, this field will be blank. Otherwise, it will be filled with an "X".

Fo every critical field that you do not want modified by anyone other than the creator, add a strict validation-by-calculation check: IsEmpty(Record_Lock), with an error message, "You are not permitted to change data that is not yours. Press the Revert Field button to exit this message."

I assume you only want to avoid innocent changes to data. In the unlikely case of users who seek to destroy the data of others, they can easily circumvent this lock by changing their name within Filemaker.

To make this a little harder, and if your users access the file from the same computer every time, you can add another text field, called Creator_Host_Name and back-fill it with their computer's network name. New records need to fill it with status(CurrentHostName)

You can then modify the Record_Lock calculation to be:

Record_Lock = Case (Creator_Name = status( CurrentUserName ) and Creator_Host_Name = status( CurrentHostName ), "", "X" )

This way, they have to change their name in Filemaker _and_ change the network name of their computer to bypass the lock.

[ August 29, 2001: Message edited by: Carey Beall ]

Link to comment
Share on other sites

This topic is 8299 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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