GetPriv
Checks if the current user has a privilege for a specified area. With this function, you can write your own Cicode functions to control user access to the system.
Syntax
GetPriv(Priv, Area)
Priv
The privilege level (1..8).
Area
The area of privilege (0..255).
Return Value
Returns 1 if the user has the specified privilege in the area, or 0 (zero) if the user does not have the privilege.
Related Functions
Example
/* User needs to have privilege 2, or cannot do operation. */
IF GetPriv(2, 0) THEN
! Do operation here
ELSE
Prompt("No privilege for command");
END
See Also