RPrinceton
Programmer
Hi Everyone,
I am using the code snippet below to obtain the last access timestamp of a file. It returns the same timestamp even though I have opened and closed the file with another application. My question is this. What constitutes a "File Access" i.e., when does the file access attribute get updated?
Thanks in advance.
RPrinceton
code snippet:
File::Stat qw
FIELDS);
$mvFileNM = "abc";
stat($mvFileNM) or die "No $mvFileNM: $!";
$mvFileLastAccTS = localtime($st_atime);
I am using the code snippet below to obtain the last access timestamp of a file. It returns the same timestamp even though I have opened and closed the file with another application. My question is this. What constitutes a "File Access" i.e., when does the file access attribute get updated?
Thanks in advance.
RPrinceton
code snippet:
File::Stat qw
$mvFileNM = "abc";
stat($mvFileNM) or die "No $mvFileNM: $!";
$mvFileLastAccTS = localtime($st_atime);