Hi,
Is it possible to get all members using multiple Roles. I have looked at the Memberservice GetMembersInRole but this only allows a single role to passed in. Is there a way to get all members who have multiple roles, for example:
GetMembersInRole("Fulltime","Teacher","Football")
If not that way would there be an alternative way?
Off the top of my head you could do something like this.
Inside a surface controller or helper class
var listofRoles = new List<string>
{
"Role1",
"Role2",
"Role3"
};
foreach (var role in listofRoles)
{
var members = MemberService.GetMembersInRole(role);
//Do what you want me the member
}
Get Members using multiple roles
Hi, Is it possible to get all members using multiple Roles. I have looked at the Memberservice GetMembersInRole but this only allows a single role to passed in. Is there a way to get all members who have multiple roles, for example:
GetMembersInRole("Fulltime","Teacher","Football")
If not that way would there be an alternative way?
Many thanks
Jon
Hi Jon,
Off the top of my head you could do something like this.
Inside a surface controller or helper class
Hope that helps!
is working on a reply...