The filesuperdate( function returns the modification date and time of a file.


This function has one parameter:

path – is a path to the file, including the file name (see Files and Folders for more information about file paths).


This function returns the modification date and time of the specified file as a superdate (see superdate(). This is especially useful for comparing two files to see which one is newer.

This example checks to see if the news.txt file is more than 36 hours old, and if so, deletes it.

if filesuperdate("~/Documents/news.txt") < supernow() - 60 * 60 * 36
    fileerase "~/Documents/news.txt"

Tip: If you want to display the date, use the superdatepattern( function.

Legacy Syntax (Separate Folder and File Parameters)

In older versions of Panorama (6.0 and earlier) the filesuperdate( function had two parameters, folderid and filename. To maintain compatibility with older databases, two parameters will still work, as shown in this example:


For new databases you’ll probably find it easier to use the single parameter mode.

See Also


10.0UpdatedCarried over from Panorama 6.0, but now may have either one parameter (path) or two (folder, path).