$findfile

From Scriptwiki
Revision as of 17:22, 20 October 2007 by Vliedel (talk | contribs) (first!)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Finds files in a specified directory.

 $findfile(dir,matchstring,N[,depth][,@window | command])

Returns the N'th matching filename, or when N=0 the number of matching filenames.

dir is the directory in which has to be searched.

matchstring is the string to match the filename.

depth is how many dirs deep have to be searched. If depth is 0 or 1, it will only search the specified dir without it's subdirs. In case you don't specify depth it will search all subdirs.

If you specify a custom window name @window which has a listbox, it will add the found files to the listbox.

If you specify the command this command will be executed for each found file, where $1- is the filename.