On Wed, 14 Dec 2005, Adedayo Adeyeye wrote: =>Thanks Dwalu. => =>Still didn't work. However, I removed use File::stat and everything works =>fine now. => =>Kind regards => =>Dayo => Apologies Dayo. I took a quick glance and missed the 'use File::stat'. Here's the quick explanation of what was happening:
perl provides a builtin function, stat, that returns a list of file information so your original line of ==>($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime, $mtime, ==>$ctime, $blksize, $blocks)=stat("Perfect.xls"); would have worked just fine on its own. (As you've just found out) The module, File::stat, overrides (replaces) perl's core function with one that returns an object so you'd need something like: use File::stat; my $fs = stat($filename); print $fs->atime; print $fs->mtime; I hope that makes sense now and clears up the previous confusion but it's much better explained via "perldoc File::stat". -- - Dwalu .peace -- I am an important person in this world - Now is the most important time in my life - My mistakes are my best teachers - So I will be fearless. - Student Creed -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>