Jump to content
Sign in to follow this  

Last Accessed/Modified Date

Recommended Posts


I want to put together a script that can scan a network drive, identify any files that have not been accessed since a specific date. For example, I want to search S drive for any doc files not accessed since January first.

Is such a script possible or has anyone had a crack at it? If so, can I please take a look at it? I just can't figure out where to start. Any help would be appreciated.



Share this post

Link to post
Share on other sites

the whole drive???

use dir command and output to a file

a cetain folder/folders?

then use filelisttoarray

thats just the start

******************************* then

Something like this?

$n_tFile = "your file name"
$n_Fdate = FileGetTime($n_tFile,1)
$sdate=$n_Fdate[0] & "/" & $n_Fdate[1] & "/" & $n_Fdate[2] & " " &  $n_Fdate[3] & ":" & $n_Fdate[4] & ":" & $n_Fdate[5]
If _DateDiff ('d',$sdate,$eDate) > 5 then


Edited by Valuater


Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...