bpal Posted April 3, 2006 Posted April 3, 2006 I have a database that I use to manage Projects for clients. I am able to set Status to Pending or Open or Closed. I want to create a script that checks to see what the status is. If status = closed then the current record should lock itself and not be modifiable. I want to be able to change the status back to open if need be but if the status is closed then the rest of the field in the current record are not modifiable. Basically I have no clue how to lock the current record at all and then base it on these conditions. Any help would be great. Thanks.
Ender Posted April 3, 2006 Posted April 3, 2006 There are a couple different approaches. First, you could use record-level access privileges to decide if the record can be edited. This would be setup in Define->Accounts & Privileges, under the privilege set's access privileges for Records (then for the desired table, select "Limited.." in the pull down at the bottom.) Use a calc, like: Status <> "Closed", which evaluates to true for the other values of Status. Another approach is to use separate layouts for Data Entry and View, and have the navigation scripts control which layout is used based on the Status: If [ Status = "Closed" and get(privilegesetname) <> "[Full Access]") ] Go to Layout [ View Project ] Else Go to Layout [ Edit Project ] End If
Recommended Posts
This topic is 6811 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