Exago .NET API Documentation
GetRole Method
Example 
WebReports.Api.Roles Namespace > RoleCollection Class : GetRole Method
The ID of the role to retrieve.
If true, the Role object will be copied into the dynamic configuration file if roleId originates from a static configuration file.
Retrieve a Role object from the collection by ID.
Syntax
public Role GetRole( 
   System.string roleId,
   System.bool forUpdate
)

Parameters

roleId
The ID of the role to retrieve.
forUpdate
If true, the Role object will be copied into the dynamic configuration file if roleId originates from a static configuration file.

Return Value

Role object representing the role requested by ID.  If no role with roleId can be found, returns null.
Example
Get a Role object for the system role with ID "End-User"
Role mySessionRole = api.Roles.GetRole("End-User");
See Also

Reference

RoleCollection Class
RoleCollection Members