0

I have some specific need here, and i don't know how to approach it. I explain :

I have a SharePoint list to which i am adding a field in feature activated event reciever. I am adding a 3 choices field.

My problem now is that i want to change the choices depending on the connected user, for example, if the user is a director the choices will be "1","2" and "3" and if the user is an emplyee the choices would be "A", "B" and "C".

Since i am doing this in feature activated event reciever it will always detect the user who is deploying (from VS) not the connected one after...

what is the appropriate event reciever here that will allow me to do this customization?

Any help will be appreciated

1 Answer 1

2

From what it seems, the only use of event receiver as I see here is creating the field options. There is no way SharePoint allow to display different values based on the person in a choice column.

  1. You can create a custom form (visual webpart or InfoPath) and then add all 6 options to the column and display only 3 based on the logged in user.

  2. Replace the choice column with a lookup and in the lookup list, set permissions to the items to the directors and employees. There will be 6 list items in the lookup list. Directors will have access to 3 and employees will have access to 3. So then the lookup will show the 3 items appropriately even in the OOTB form.

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.