Newbies Rainydayfun Posted May 9, 2016 Newbies Posted May 9, 2016 I'm a novice & I'm trying to lock /disable a field based on the current user. I don't want the field to disappear if the user is not authorized to modify it. I want it to be visible to unauthorized users, but modifiable to authorized users. Here's the script I'm trying to use: If [Get(AccountName)] If [Get(AccountName) = "boss1" or [Get(AccountName)] = "boss2" Else Set Field [Table::Next Tab] End If End If
comment Posted May 9, 2016 Posted May 9, 2016 6 minutes ago, Rainydayfun said: I want it to be visible to unauthorized users, but modifiable to authorized users. You set this up in the users privilege set. Choose [Custom privileges …] for Records, then [Limited…] for Field Access, and make the field «view only». Not sure what role the script is playing here.
Newbies Rainydayfun Posted May 9, 2016 Author Newbies Posted May 9, 2016 Thank you for the quick reply. The boss helped me. He ended up using the inspector to create an edit box & a popup menu. We set the popup menu to hide if the account name isn't one of the two authorized bosses. If it IS them, they can modify the popup. The edit box is unmodifiable, placed on top the popup, & shows the value that one of the bosses chooses in the popup.
comment Posted May 9, 2016 Posted May 9, 2016 You should not rely on layout measures to provide security.
Rick Whitelaw Posted May 9, 2016 Posted May 9, 2016 What Comment says but also your script doesn't make any sense to me.
Recommended Posts
This topic is 3420 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