Windows apps
Collapse the table of content
Expand the table of content
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

length property

Returns the number of files contained in a FileList object.

This property is read-only.

Internet Explorer 10



var numFiles = object.length; 

Property values

Type: number

The number of File objects in the FileList object.


Returns the number of files that are selected and available on the FileList object. This value can be greater than or equal to 1 if multiple file selection is enabled (typically via the multiple attribute on the input element). If no files have been selected, 0 is returned.

See also




© 2016 Microsoft