This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D v19.8
SET ALLOWED METHODS
|
SET ALLOWED METHODS ( methodsArray ) | ||||||||
Parameter | Type | Description | ||||||
methodsArray | Text array |
![]() |
Array of method names | |||||
The SET ALLOWED METHODS command designates the project methods that can be called directly from the application.
4D includes a security mechanism that filters callable project methods from the following contexts:
By default, if you do not use the SET ALLOWED METHODS command, no method is callable (using an unauthorized method in an expression causes an error).
In the methodsArray parameter, pass the name of an array containing the list of methods to offer in the Formula editor. The array must have been set previously.
You can use the wildcard character (@) in method names to define one or more authorized method groups.
If you would like the user to be able to call 4D commands that are unauthorized by default or plug-in commands, you must use specific methods that handle these commands.
Note: Formula filtering access can be disabled for all users or for the Designer and Administrator via an option on the "Security" page of the Database Settings (see Data Access). If the "Disabled for all" option is checked, the SET ALLOWED METHODS command will have no effect.
This example authorizes all methods starting with “formula” and the “Total_general” method to be executed by the user in protected contexts:
ARRAY TEXT(methodsArray;2)
methodsArray{1}:="formula@"
methodsArray{2}:="Total_general"
SET ALLOWED METHODS(methodsArray)
Product: 4D
Theme: Formulas
Number:
805
Modified: 4D 2004.4
Modified: 4D v17 R2
4D Language Reference ( 4D v19)
4D Language Reference ( 4D v19.1)
4D Language Reference ( 4D v19.4)
4D Language Reference ( 4D v19.5)
4D Language Reference ( 4D v19.6)
4D Language Reference ( 4D v19.7)
4D Language Reference ( 4D v19.8)