# %fsize() function

The %fsize() function returns the size
in bytes of the file associated to the opened *file.descriptor* returned by a previous call to %open() or %creat().

## Syntax

```
size = %fsize(file.descriptor)
```

## Description

If the file does not exist or
is not readable, -1 is returned.

## See also

- [%close() function](https://d3codex.com/pickbasic-flashbasic/percent-close-function/)
- [%creat() function](https://d3codex.com/pickbasic-flashbasic/percent-creat-function/)
- [%open() function](https://d3codex.com/pickbasic-flashbasic/percent-open-function/)
- [FlashBASIC C functions overview](https://d3codex.com/pickbasic-flashbasic/flashbasic-c-functions-overview/)
- [cfunction statement](https://d3codex.com/pickbasic-flashbasic/cfunction-statement/)

---
Source: https://d3codex.com/pickbasic-flashbasic/percent-fsize-function/ - part of the D3Codex reference.
