WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

Directory and Deltree UDFs

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

Get file access times for dir

#DefineFunction WriteTimeInfo(handle,dir)
   origdir=DirGet()
   DirChange(dir)
   BoxText(dir)
   flist=FileItemize("*.*")
   fcount=ItemCount(flist,@tab)
   for xx=1 to fcount
      thisfile=ItemExtract(xx,flist,@tab)
      thistime=FileTimeGetEx(thisfile,3)
      FileWrite(handle,strcat(dir,thisfile,@tab,thistime))
   next
   dirlist=DirItemize("*.*")
   dircount=ItemCount(dirlist,@tab)
   total=FileSizeEx("*.*")+0.0
   for xx=1 to dircount
      thisdir=ItemExtract(xx,dirlist,@tab)
      WriteTimeInfo(handle,thisdir)
   next
   DirChange(origdir)
   return
#EndFunction




;True start of program
fn="C:\temp\timeinfo.txt"
examine="\\SERVER\SHARE\DIR"

IntControl(5,1,0,0,0)      ;Allow system and hidden filesto be counted
handle=FileOpen(fn,"WRITE")

BoxOpen("File Size Inspector","Reading Initial Directories")
WriteTimeInfo(handle,examine)


FileCLose(handle)
Message("All","Done")
run("browser.exe",fn)


Exit
   

Article ID:   W14992
File Created: 2001:11:08:12:41:18
Last Updated: 2001:11:08:12:41:18