SetPermissions Method (ADOX)
GroupOrUser.SetPermissions Name, ObjectType, Action, Rights [, Inherit] [, ObjectTypeId]
A String value that specifies the name of the object for which to set permissions.
A Long value which can be one of the ObjectTypeEnum constants, that specifies the type of the object for which to get permissions.
A Long value which can be one of the ActionEnum constants that specifies the type of action to perform when setting permissions.
A Long value which can be a bitmask of one or more of the RightsEnum constants, that indicates the rights to set.
Optional. A Long value which can be one of the InheritTypeEnum constants, that specifies how objects will inherit these permissions. The default value is adInheritNone.
Optional. A Variant value that specifies the GUID for a provider object type that is not defined by the OLE DB specification. This parameter is required if ObjectType is set to adPermObjProviderSpecific; otherwise, it is not used.
An error will occur if the provider does not support setting access rights for groups or users.
When calling SetPermissions, setting Actions to adAccessRevoke overrides any settings of the Rights parameter. Do not set Actions to adAccessRevoke if you want the rights specified in the Rights parameter to take effect.
|Group Object (ADOX)||User Object (ADOX)|