File Class

https://w3c.github.io/FileAPI/#file-section

public sealed class File : Blob
Inheritance
Blob File

Constructors

NameDescription
File(IReadOnlyList<object>, string, FilePropertyBag?)Creates a file from the given parts, name and options.

File(IReadOnlyList<object>, string, FilePropertyBag?)

File.cs

Creates a file from the given parts, name and options.

public File(IReadOnlyList<object> fileBits, string fileName, FilePropertyBag? options = null)

Properties

NameDescription
LastModifiedGets the last modification date of the file, in milliseconds since the Unix epoch.
NameGets the name of the file.
WebkitRelativePathGets the path of the file relative to the directory that was selected or dropped (e.g. photos/2024/a.jpg) in a file input with the webkitdirectory attribute, or an empty string.

LastModified

File.cs

Gets the last modification date of the file, in milliseconds since the Unix epoch.

public long LastModified { get; }

Gets the name of the file.

public string Name { get; }

WebkitRelativePath

File.cs

Gets the path of the file relative to the directory that was selected or dropped (e.g. photos/2024/a.jpg) in a file input with the webkitdirectory attribute, or an empty string.

public string WebkitRelativePath { get; }