File_Records(..., Close_File)

File_Records(..., Close_File)

Description

Close created file in script.

Syntax

File_Records(file_number, Close_File);

Parameters

Variable

Input

Variable

Input

file_number

FILE_1 - Close file 1

FILE_2 - Close file 2

FILE_3 - Close file 3

Returns

Return value

Return explanation

SCRIPT_OPERATION_SUCCESS

Success

Function call example

Create/Write/Close file from File_Records
new file_array{}= "information to store: 234"; main() { File_Records(FILE_1, Create_File, "File_test.bin"); // creates FILE_1 record with name `File_test.bin` File_Records(FILE_1, Write_File, file_array, 25); // writes array information to FILE_1 record File_Records(FILE_1, Close_File); // closes FILE_1 record for(;;) { Delay(1000); } }

Notes and Warnings

Make sure to note that after closing Record (file) you won’t be able to edit it.

Used in Examples

File Records example