JCL Help:SetDirLastAccess

From Project JEDI Wiki
Jump to navigationJump to search


Summary

Sets the directory's last-write time stamp.


Pascal

 function SetDirLastAccess(const DirName: string; const DateTime: TDateTime): Boolean;


Parameters

Parameters Description
const DirName: string The name of the directory for which to set the time of last write.
const DateTime: TDateTime The date and time to set the file's last write stamp to. You must supply the UTC based date and time. To convert from a local date and time use the LocalDateTimeToDateTime function from JclDateTime.


Return Value

If the function succeeds the result is True, otherwise it's False.


Description

SetDirLastWrite sets the specified directories last-access timestamp to the supplied datetime. This routine cannot be used to set the last-access timestamp of a file. Use SetFileLastAccess for that. This routine only works on Windows NT/Windows 2000 and for it to succeed the caller must have backup privileges (SE_BACKUP_NAME and SE_RESTORE_NAME).


See Also

SetDirLastWrite SetDirCreation


About

Unit

JclFileUtils


Donator

Marcel van Brakel


Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page