I want to create custom action in c# code for sharepoint list.
I am using SPUserCustomAction type and i need to display this item only for specific users (user are presented in specific group)
Location set to “Microsoft.SharePoint.StandardMenu”;
How can I specify in code that only few users that belongs to my custom group can see this menu item? Any links?
Thanks.
The
RightsAttribute is your friend. Here you can set which rights are required for your custom action to be shown like so:The rights are based on the
SPBasePermissionenumeration which you can find here.Also see this blog post about security trimming custom actions.