Skip to content

Set File

Creates or updates a file on the the server.

Permissions

Command KindNeeded User Kind
WriteAdmin, Designer, Sys

Parameters

NameTypeDescriptionRequiredDefaultValues
FilestringName/path of the file ([Directory/File]). The root directory is the 'Files' directory of the database on the server.yes
Base64booleanIf 'True' the file is base64 encoded. The default value is 'False'. This is useful if file is not a text file.nofalse
CreateDirectorybooleanIf 'True', the target directory will be created if it does not exist. Only the last directory will be created and not the entire directory tree. The default value is 'True'.notrue
OverwritebooleanIf 'True' an existing file is overwritten. The default value is 'True'.notrue
Textarray of stringText of the file.no

Result

NameTypeDescription
KindstringKind of the file: File or Directory.
NamestringName of the file.
FilestringName and path of the file.
ParentstringParent directory of the file.
SizenumberSize of the file in kilobyte.
PermissionsintegerNumber of permissions of the file.

Code

text
SET FILE
FILE=[string, Needed]
BASE64=[boolean, default=false]
CREATEDIRECTORY=[boolean, default=true]
OVERWRITE=[boolean, default=true]
TEXT=[string, Multiple]