fileFileDate

Returns the date a file was last written. Takes a filename. Returns the date in the same form as sysCurrentDate ("04 Nov 2026"), in local time, or "" if the file doesn't exist.

File IO

Parameters & Returns

Parameters

filename String

Returns

String

Quick Summary

Returns the date a file was last written. Takes a filename. Returns the date in the same form as sysCurrentDate ("04 Nov 2026"), in local time, or "" if the file doesn't exist.

Technical Exegesis...

Returns the date the file was last written (changed), in the same form as sysCurrentDate: "DD MMM YYYY", for example "04 Nov 2026", in local time. Returns "" if the file doesn't exist. The file doesn't need to be open. Works for folders as well on desktop.

Use fileFileTime for the time of day, and fileFileStamp to compare two files or to work out how old one is.

Web: files are kept by the browser, and the time is recorded whenever one is written. A file saved before version 1.

Example

Example.bam
Local f:Int = fileWriteFile("save.dat")
fileWriteLine(f, "level 3")
fileCloseFile(f)

Print "Saved on " & fileFileDate("save.dat") & " at " & fileFileTime("save.dat")