I have a drop down list box which lists roles. I want to get the list of users having that role. I mean list of users that are in \"Administrator\" role or \"CanEdit\" role.
the code working for me was as following:
var users = roleManager.FindByName(roleName).Users.Select(x => x.UserId); var usersInRole = Users.Where(u => users.Contains(u.Id));