AX2374

GetSecurityInfo("TableType")

If "TableType" is specified as the first parameter, GetSecurityInfo returns the user's table type permissions, given a table type.

Syntax

GetSecurityInfo("TableType", "TableTypeName", "UserName", LocalizeResult, "Domain", ReturnWriteFilter)

Parameter Description

TableType

Use the keyword TableType to return information on the user's table type access filter.

TableTypeName

The name of the table type.

UserName

Optional. The name of the user or role for which to return the security information. If omitted, the current user is assumed.

LocalizeResult

Optional. Boolean value to determine whether the table type permission is returned using integer values or by using the permission name in security.

  • If FALSE (default), the function returns "0" to indicate no access, and "1" to indicate full access.
  • If TRUE, the function returns the permission names "No Access" or "Full Access".

If the user's access is filtered, the filter text is returned.

Domain

Optional. The Active Directory domain of the user.

The domain property only applies to users that have been imported from Active Directory. Manually created users do not have a value for domain.

You might be required to specify a domain to identify the correct user if users have been imported from multiple Active Directory domains and have the same user name. If all user names are unique across domains, then it is not necessary to specify the domain.

ReturnWriteFilter

Optional. Boolean value to determine whether the function returns the user's read permissions or the user's write permissions.

  • If FALSE (default), the function returns the user's read permissions to the table type.
  • If TRUE, the function returns the user's write permissions to the table type.

By default, a user's read and write permissions are the same unless different write permissions are explicitly defined. So in most cases, returning the read filter returns the user's overall access to the table type. However, if you need to return the write access specifically, you can use this parameter to do so.

All non-numeric entries must be placed in double quotation marks, unless you are using cell references to reference the text held in another cell. However, the Boolean values TRUE and FALSE should not be in quotation marks.

Remarks

  • The user's effective permissions are returned, including any access inheritance from a role or admin rights, and subsystem restrictions (if applicable).

  • If the filter uses a filter variable (such as {CurrentUser.LoginName}), the variable is resolved when the function returns values for a user, and not resolved when the function returns values for a role.

  • GetSecurityInfo is a volatile function.

Examples

=GetSecurityInfo("TableType","GLData")

This example returns "0" if the current user has no read access to table type GLData.

=GetSecurityInfo("TableType","GLData",,TRUE)

This example returns "No Access" if the current user has no read access to table type GLData.

=GetSecurityInfo("TableType","GLData","Jdoe")

This example returns "(DEPT.Region='North')" if user Jdoe has filtered read access to table type GLData.

=GetSecurityInfo("TableType","GLData","Jdoe",,"Corporate")

This example returns the table type filter for the user Jdoe who was imported from the Corporate domain. This would be necessary if another user named Jdoe was imported from a different Active Directory domain.

=GetSecurityInfo("TableType","GLData",,TRUE,,TRUE)

This example returns "No Access" if the current user has no write access to table type GLData. The user might also have no read access to the table type, or the user might have full or filtered read access to the table type but no write access to the table type. The sixth parameter is used to specifically return the write access, regardless of what the user's read access is.