Please enable JavaScript to view this site.

Navigation: Advanced topics > Events > Table events

Get Table Permissions

Scroll Prev Next More

Description

The GetTablePermissions event occurs after the table is initialized. Use this event to assign user a different set of permissions.

Syntax

GetTablePermissions(permissions)

Arguments

permissions

a string containing permissions calculated for a given user and table.

Return value

a string containing permissions calculated for a given user and table.

A - Add;

D - Delete;

E - Edit;

S - List/View/Search;

P - Print/Export;

I - Import;

M - Admin option. A user can see all records in the table.

Applies to pages

All table specific pages like List, Print, Edit, List, Add, Export etc.

Example

Prohibit the editing of table data on the weekends:

 

dw=Weekday(Now(),1)
if dw=1 or dw=7 then
  permissions="S"
end if
 
GetTablePermissions = permissions

See also:

Security API: setPermissions

Security API :getPermissions

User group permissions

Choose Pages Screen

Event: After table initialized

Event: IsRecordEditable