Back to product page

Size property


Holds size of the file or directory (lower 32 bits).

Type

A Long value

Syntax

  • Basic
object.Size [= value]
The Size(object,value) syntax has these parts:
objectAn expression evaluating to an object of type DirItem.
valueA Long value.

Remarks

This property will contain size of the file or folder (whatever is stored in the item). Typically, it will be presented in bytes, but it is possible that some FTP servers use other form of representation, such as blocks (of whatever size). If size of remote file is larger than 2.7GB, this value can become negative - in which case we suggest you convert it to a double and add MAX_UNSIGNED+1 (4294967296) to it. If size of remote file is larger than 4.2GB, you should also use SizeHi property value.

Just a reminder - you must call ListDir to get directory listing, and then access files through Ftp.DirItems property in order for this property to be available!

Platforms

Windows