Syntax

fileWrite(fid, string_byte_or_bytearray)

Package

file

Alias

Pkg Usage

open(fid, string_byte_or_bytearray)

Description

Writes text or byte data to an open file.

Writes text or byte data to an open file.

Parameters

Parameter name

Type

Required

Description

fid

String

Yes

The id of the open file to write to.

string_byte_or_bytearray

String/Byten

Yes

The text string or byte data to write to the file.

Return Type

None

Return value has no meaning.

Error Handling

Throws String

Error: "write_error": followed by the actual error

Example

Example 1

use "file";
int fid = open(filename); //fileOpen
fileWrite(fid, "First line is here
"); //full name of the routine
write(fid, "Second line is here
");
close(fid); //fileClose

See also

defaultcom.atlassian.ecosystemfc909b09-b512-4c31-a844-dd855b0e6aae/db1c8759-c7e5-4e80-9022-d19e47b0e2b0/static/macroPeacocka0c22d8e-6c3d-4086-9cf9-5b43307a86e8ari:cloud:ecosystem::extension/fc909b09-b512-4c31-a844-dd855b0e6aae/db1c8759-c7e5-4e80-9022-d19e47b0e2b0/static/macroPeacockfb5b7dc3-11f8-4f97-a82d-824c0866ee99defaultcom.atlassian.ecosystemfc909b09-b512-4c31-a844-dd855b0e6aae/db1c8759-c7e5-4e80-9022-d19e47b0e2b0/static/macroPeacocka0c22d8e-6c3d-4086-9cf9-5b43307a86e8ari:cloud:ecosystem::extension/fc909b09-b512-4c31-a844-dd855b0e6aae/db1c8759-c7e5-4e80-9022-d19e47b0e2b0/static/macroPeacockfb5b7dc3-11f8-4f97-a82d-824c0866ee99