Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

On the group settings page, it looks like membership visibility is limited to either "Group Members" or "Everyone". Is it possible to restrict membership visibility of a group to something other than those two options?

My preference would be to allow visibility of Group A to the members of Group B but I don't know where/how to set this up.

Is this possible?

share|improve this question
add comment

2 Answers

up vote 0 down vote accepted

It looks like the property that determines who can view the members is a boolean value: SPGroup.OnlyAllowMembersViewMembership, therefore you're not going to be able to set it to other groups or users.

If you really need to allow other groups (but not everyone) to see the members, you will need to write custom code.

share|improve this answer
    
Great, thanks Laurie. I'm not averse to writing custom code (I prefer it, actually) but being new to SharePoint, I'm not sure exactly where or how this code would hook into SharePoint. –  Robert Jun 30 '11 at 21:56
    
You can use a DelegateControl Feature so you can execute your code-behind when loading the people.aspx page. Here is an article that describes how to do this: sharepointmagazine.net/articles/…. –  Laurie Jun 30 '11 at 22:21
add comment

This is in particular annoying, because membership is visible also to unauthenticated (anonymous) users. So the solution would be to restrict visibility to "Group Members" and write custom code for a view by a group like "authenticated users"?

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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