Pregunta

I need to create a SharePoint 2013 field that only accepts groups (from SP, not AD). I know I can add UserSelectionMode="PeopleOnly" to make it accept only people, but I want the opposite. Is there any way I can accomplish this? Thanks!

EDIT1: Just to clarify, I do not want to pick users from a specific group, but select "SPGroup"s from a people picker control

EDIT2: Thanks for all the help! For now, I'm gonna go with an event receiver to validate the value against the groups of the site. Maybe I'll change to the PrincipalAccountType solution later.

¿Fue útil?

Solución

Try modifying PrincipalAccountType="SPGroup" as MSDN says.

String used to specify the type of principals to be resolved in a query Comma-separated : "User,DL,SecGroup,SPGroup"

Otros consejos

Create field and while creating come at down near Choose from option and select Share Point Groups and define group name under Choose from:.

Hope this will help you...

You can use UserSelectionScope="GroupID" attribute to specify a group in your CAML query. GroupID is a group ID (integer).

You can see property description on the MSDN field schema description page

Licenciado bajo: CC-BY-SA con atribución
scroll top