in reply to Re: folder properties / modified date
in thread folder properties / modified date

Thanks for your help - your node seems pretty comprehensive and I'll have a shot at it.
I also tried snadra's idea which works fine on my NT4 system but doesn't work fine on Win2k. Any idea why ? Here's my bit of code...
####################### PRAGMA ####################### use strict; ####################### IMPORT ####################### use file::stat; my $file = "d:\\brossad\\"; # your own folder name here my @info = stat($file); my $last_access = $info[8]; my $last_modification = $info[9]; if (@info) { #print $last_access."\n"; my @time = (localtime($last_access)); $time[4]++; $time[5] += 1900; print ("time : $time[2]:$time[1]:$time[0] "."- $time[3]/$time[4]/$t +ime[5].\n"); } else { print "oops\n"; }
It returns :
time : 14:4:12 - 21/7/2003 on my machine
, and
time :  0:0:0  - 21/7/2003 on a Win2k machine... :(

I checked the epoch time stamps (just to make sure the conversion bit wasn't the failing part) and the stamps are wrong under Win2k.

Replies are listed 'Best First'.
Re: Re: folder properties / modified date
by Foggy Bottoms (Monk) on Jul 21, 2003 at 13:58 UTC
    I think I found out why time didn't come out for the
    last accessed
    property : it just doesn't exist in the Win98/2k folder properties - only the date is there. Oh well (sighs heavily).
    Thanks for your help.