How do I make a field enabled in new mode, but only visible to certain groups in edit/display mode?

  • 18 December 2018
  • 6 replies
  • 10 views

Badge +6

There is a certain field on my form that consists of PII data.  I would like the User to be able to enter info into this field when submitting a new form.

But in List View and Edit/Display Mode, I only want this field to be visible to a certain User Group.  Is that possible?


6 replies

Userlevel 5
Badge +13

You can place a rule on the form control and hide it for users not in a specific SharePoint group using the formula below.

not(fn-IsMemberOfGroup("Your SharePoint Group Name"))

You can also mix in the "Is New Mode", "Is Edit Mode" and "Is Display Mode" options from the Common tab into the formula.

Badge +6

That doesn't work in this case.

I have 2 User Groups.  "Everyone" and "Managers."  PII field in question is "Account #"

When a User (Everyone) adds a new Item, I want them to have access to enter an Account #.  Once they save the Item, the Account # field will no longer be visible to them.  The only folks that will be able to view that field going forward (in Edit and Display Mode), is the Managers. 

Userlevel 2
Badge +11

Disable field if: not(New Form)

Hide field if: and(not(New Form),not(IsMemberOfGroup("Managers")))

NB: if the IsMemberOfGroup inline function is not listed, just type it as fn-IsMemberOfGroup

Badge +6

Thanks for the reply! 

Those formulas don't seem to work for me.  Do I also need to use "fn-and" ad "fn-not"?  I couldn't get those to work either...

Userlevel 2
Badge +11

That's odd, as the listed inline functions should work without any issues. Are any of the inline functions working. Just to be sure: use a calculated field on the form to show results for logic operation, e.g. and(true,true) -> true, and(true, false) -> false.

Are you using the correct separators , or ; in the functions?

Is it a classical form or a responsive form?

Badge +6

I got it!  I missed your call out on adding the "fn-" before Is Member.

Thank you for your help!

Reply