Returns the size of a file in bytes.

Syntax

<oRef>.size(<filename expC>)

<oRef>

A reference to a File object.

<filename expC>

The name of the file to check. Wildcard characters are not allowed; you must specify the actual file name.

If you specify a file without including its path, dBASE Plus looks for the file in the current directory, then in the search path(s) you specified with SET PATH, if any. If you specify a file without including its extension, dBASE Plus assumes no extension. If the named file cannot be found, an exception occurs.

Property of

File

Description

Use size( ) to determine the size of a file on disk.

With the byte-level access methods of the File object, dBASE Plus doesn’t update the size on the file recorded on the disk until you close( ) the file.