fileClose
Shared
Closes a file, writing what is left, and destroys its element.
bool fileClose(file file)
Parameters
| Name | Type | Description |
|---|---|---|
| file | file | A file opened by fileOpen or fileCreate. |
Returns
true.
Example
local file = fileOpen("notes.txt")
if file then
fileWrite(file, "hello")
fileClose(file)
end