O’ holly ones,….Greetings. I have the following script
#! Path to perl.exe -w use strict; use diagnostics; use warnings 'all'; use Win32; use Win32::OLE; use Win32::ODBC; use File::Find; use File::stat; use time::localtime; use vars qw/%data/; $data{path} = $ARGV[0]; system("cls"); print "\n\nTarget Path=> $data{path}\n"; find sub { print $File::Find::name, $/ if -f _; },$data{path};
What I would like to obtain is a display like so if my @ARGV1 is adrive letter or folder.
drive\folers1 File1.snd File2.sop File3.xxs dive\folder2 File10.dod File34.opo . . .
And so on…

Can you please enlighten me on to how Can I achieve this?

Also, And more importantly if these files are hosted ona DFS share how can I obtain the UNC path to those files.

Your help is really really highly appreciated and example would go along way….Thanks.

**************UPDATE*************

A bit of background info



I need to write a script that stats only files. For example I have a drive “t:\” (Which is a DFS represented shared area). And I need to get a list of all files is this drive and their full path, their sizes, creation date, last modified date, last accessed date, the owner of this file, and it UNC path (i.e which server this file is on).

Now in this bit of code
find sub { print $File::Find::name, $/ if -f _; },$data{path};
I need to do something like the below (not sure how)
my $file_stat = stat ($File::Find::name); print $creation_date; print $modified_date; print $accessed_date; print $file_owner; print $Full_file_path; print $file_size
Since I haven't got a clue on how to begin and what to do, so your help - I couldn't stress it any more - is very very vital to me.

Thanks
Blackadder

In reply to Stats for files using File::Find and DFS information by blackadder

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.