Verify if SharePoint user is in Group

Once in a while, I find really great things available in SharePoint object model. The other day I was working on custom SharePoint security component and discovered quite few usefull properties in SPWeb.Groups ->  SPGroup. In my case I had to determine whether current user belongs to a group and this is exactly a property of the SPGroup object ContainsCurrentUser. Another usefull one CanCurrentUserManageGroup.

Above properties can be used in a custom navigation control or any view logic that toggles the state depending on whether current user is in group that has access to the data.

Here is more details on the topic

This entry was posted in MOSS, sharepoint and tagged , , , . Bookmark the permalink.

Comments are closed.