The fileattributes( function returns attributes of the specified file or folder (date, owner, permissions, etc.).


This function has one parameter:

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


This function returns a dictionary containing the attributes of the specified file or folder. You can use the getdictionaryvalue( function to extract individual attributes. For example, this code will display the modification date of the Flower.jpg file.

message superdatestr(getdictionaryvalue(fileattributes("~/Pictures/Flower.jpg"),"MODIFIED"))

The attribute dictionary contains about a dozen items. The primary items are:

There are several additional items that quite frankly, we don’t understand. However, these are attributes supported by macOS, so they are included.

See Also


10.2NewNew in this version.