FolderItem.CreationDate
From Xojo Documentation
This item was deprecated in version 2019r2. Please use FolderItem.CreationDateTime as a replacement. |
or
DateValue = aFolderItem.CreationDate
Supported for all project types and targets.
The creation date of the FolderItem.
Notes
Do not modify the CreationDate directly. Instead always assign a new Date instance to it. Refer to the example below.
On Windows, the CreationDate cannot be changed if the file is open. This includes if it is open using a BinaryStream, TextInputStream or TextOutputStream. Close the file before changing the CreationDate.
On Linux, the CreationDate cannot be modified. Attempting to change it raises an UnsupportedOperationException. Also, the CreationDate may not be accurate as many Linux file systems do NOT actually track the creation date.
Example
This example displays the creation date in the ShortDate format.
Changing CreationDate is slightly more complex. You cannot just change the CreationDate property directly because you will simply be changing a date that is not persistent. Instead you need to create a new date instance with the date you want and then assign that to CreationDate. Here is an example that sets a file's creation date to the current date and time: