FilePickerFile
Metadata for a file selected via flet.FilePicker.pick_files.
Returned by flet.FilePicker.pick_files and used as input context for FilePickerUploadFile when uploading selected files.
Properties
Properties
bytesclass-attributeinstance-attribute
bytes: Optional[bytes] = NoneFile contents.
Returned only when pick_files is called with
with_data=True. Otherwise this value is None.
idinstance-attribute
id: intSelection-scoped file identifier assigned by Flet.
This value is stable for the current picker selection and is preferred for upload matching in FilePickerUploadFile.
pathclass-attributeinstance-attribute
path: Optional[str] = NoneAbsolute path to the selected file, when available.
Note
- Web mode always returns
None. - On native platforms, this can still be
Noneif the platform picker does not expose a filesystem path.