Click or drag to resize

IPermissionsChange Method (String, Boolean, NullableGuid)

Change the value of the specified permission.
It will not save the change in the database unless you explicitly call the Save method.

Namespace:  AskiaPortalCmn.Common
Assembly:  AskiaPortalCmn (in AskiaPortalCmn.dll) Version: 1.7.0-build068
Syntax
IReturnValue Change(
	string key,
	bool isAllowed,
	Nullable<Guid> moduleGuid = null
)

Parameters

key
Type: SystemString
Indicates the permission to modify
isAllowed
Type: SystemBoolean
Indicates the value to set
moduleGuid (Optional)
Type: SystemNullableGuid
Indicates the GUID of the module that contains the permission
It uses the current module CurrentModule if the value is null

Return Value

Type: IReturnValue
It return unsuccessful value, if the user in the context doesn't have enough permission to do this action
Remarks
Administrator allowed to modify the permission of a user, could not change permission higher than his own permission.
It will not save the change in the database unless you explicitly call the Save method.
See Also