File modification time: Difference between revisions
Initial FutureBasic task solution added
m (Update Lang example: Fix spelling of Lang) |
(Initial FutureBasic task solution added) |
||
Line 612:
AD 2022-01-01 AM 05:00:00.000 (Sat) Mountain Standard Time
</pre>
=={{header|FutureBasic}}==
<syntaxhighlight lang="futurebasic">
CFURLRef desktopURL = fn FileManagerURLForDirectory( NSDesktopDirectory, NSUserDomainMask )
CFURLRef url = fn URLByAppendingPathComponent( desktopURL, @"file.txt" )
CFDictionaryRef dict = fn FileManagerAttributesOfItemAtURL( url )
print dict[@NSFileModificationDate] // Read file's current date
// Reset file date to current
fn FileManagerSetAttributesOfItemAtURL( CFURLRef url, @{NSFileModificationDate:fn DateNow )
</syntaxhighlight>
=={{header|Gambas}}==
|