Link to home
Start Free TrialLog in
Avatar of Isaac
IsaacFlag for United States of America

asked on

disable infoPath field based on sharepoint list value

I have a list in SharePoint 2013 called "Managers"  that has the names of users.

I also have an infoPath form that has a few fields.  On the form, there are certain fields that only the manager can have access to. I would  those fields to be enabled only for the manager.  It should be disabled for everybody else.

Any ideas?

Thanks!
Avatar of melli111
melli111
Flag of United States of America image

On the fields that you wish to disable, you need to add conditional formatting.  You'll go into Manage Rules, new, formatting.  Then you'll write your condition.  Your condition would be something along the lines of if currentuser does not equal managerusername(any occurrence) then disable this control.  This is assuming you already have a receive data connection to access the managers list.  If you need more detailed steps please let me know.
Avatar of infoalex
infoalex

1. Create SharePoint hosted WCF service returning Security Group name of the current user
2. In InfoPath create data connection to this service
3. For the selected field within InfoPath implement conditional formatting (control disabling). As a data source select the one described in the previous step. Ensure the field is enabled only for the Owner Group users.
Avatar of Isaac

ASKER

melli111,

There is no currentuser in the drop down of the condition
Is the InfoPath form on the Managers list?
Avatar of Isaac

ASKER

What do you mean?
ASKER CERTIFIED SOLUTION
Avatar of melli111
melli111
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial