eep! LONG LINES!!

The $file.name and $File.Move are FSO object commands/references. The UDF DIRPlus returns an array of FSO objects of the requested files and or folders.

other FSO items.. are.

$file.path ;this is the full path to the file.
$file.datelastmodified ;the date of the last change to the file.

there are a lot....

here is a simple example of what DIRPlus is doing (minus directory recursion, and the filter options.)

Code:



$folder = "%temp%"

;this returns the specified Folder's FSO handle
$Folder_FSO = CreateObject("Scripting.FileSystemObject").getfolder($folder)

;this will list all subfolders in the root of $folder
for each $Subfolder in $Folder_FSO.subfolders
? $SubFolder.name
next

;this will list all files on the root of $Folder
For each $file in $Folder_FSO.files
? $File.name
next




DIRPlus takes those 2 simple steps and expands on them. It gives you the options to do a recursive directory crawl, with some strong filter options built into it. The UDF was built and modeled after a DOS DIR command.

For more information on all what you can do with FSO object.

Bryce