Click or drag to resize

VGRolesInstanceFindUsersInRole Method (String, String)

Note: This API is now obsolete.

Gets a list of users in a specified role where the user name contains the specified user name to match.

Namespace:  Novalys.VisualGuard.Security.Membership
Assembly:  Novalys.VisualGuard.Security (in Novalys.VisualGuard.Security.dll) Version: 2019.1.831.19 (2019.1.0831.19)
Syntax
[ObsoleteAttribute("Use FindUsersInRole(VGRole role, string usernameToMatch) method")]
public string[] FindUsersInRole(
	string roleName,
	string usernameToMatch
)

Parameters

roleName
Type: SystemString
The role to search in. For shared role the value must be prefixed by '#'.
usernameToMatch
Type: SystemString
The user name to search for.

Return Value

Type: String
A string array containing the names of all the users whose user name matches usernameToMatch and who are members of the specified role.
Exceptions
ExceptionCondition
ArgumentNullExceptionroleName is null (Nothing in Visual Basic).

-or-

usernameToMatch is null.
ArgumentExceptionroleName is an empty string or contains invalid invalid chars ('\', '/', '?', '*', '%', ';', ''', '"', ':', '|', '[', ']', '+', '=', ',') or is longer than 64 characters.

-or-

role identified by roleName does not exists in the repository.

-or-

usernameToMatch is an empty string.
Remarks
Wildcards such as asterisks and question marks can be used in the usernameToMatch parameter value.
See Also