Hi,
This would be probably best to do with using either a custom query or the general User select method. The key thing is that you need to filter out the Users that aren't members of the searched Role, which involves using an inner SELECT inside the Where condition.
In the API, you can use the method:
UserInfoProvider.GetUsers(where, orderBy)
the
where Where condition would be something like:
UserID IN (SELECT UserID FROM CMS_UserRole
WHERE RoleID = <id of the searched Role>)
AND UserCustomField = <searched value>
The GetUsers method internally selects all the fields in the CMS_User and CMS_UserSettings tables (connected in a View), unless you specify a limited set of columns by the Columns property of the three-argument GetUsers method overload.
Regards,
Zdenek