ISProvider.UserGrants

Description

The collection of the users being granted the access to some actions of the provider within Profile.

Syntax

object.UserGrants(aIncludeDeleted)

Part Attribute Type Description
object Required
The object always implements the ISProvider interface
aIncludeDeleted In, Required
bool
Returns true if the revoked users are included
Restriction: This property is readonly.

Return Value

ISCollection

Example

Display the collection of the users being granted the access to some actions of the provider within Profile.

Dim aFilter 
Dim aProviders, aProvider
Dim aUserGrants, aUserGrant
Dim aMessage

const aIncludeDeleted = true

Set aFilter = Profile.CreateProvidersFilter
aFilter.Category = 2 'pcProvider

set aProviders = Profile.LoadProvidersByFilter(aFilter)

for each aProvider in aProviders
  aMessage = aMessage & vbNewLine & vbNewLine & aProvider.FullName

  set aUserGrants = aProvider.UserGrants(aIncludeDeleted)
  if aUserGrants.Count = 0 then
    aMessage = aMessage & " has no users being granted the access"  
  end if
  
  for i = 0 to aUserGrants.Count - 1 
    set aUserGrant = aUserGrants.Item(i)
    aMessage = aMessage & vbNewLine & "      User Name: " &_ 
      aUserGrant.Grantee.FullName 
  next 'i
next 'aProvider  
 
Profile.MsgBox (aMessage) 
Note:

In Profile Client v8 on User Interface User Grants can be found in Organisation > People&Places > People and Places > Open the selected Provider > Grants > Users and Roles.

Version information

Added in v8.3.0
parameter aIncludeDeleted added in v8.3.0