hello!
i want to get all the filenames of a specific file-type in one specific directory.
i think, i'll have to use FindFirst, FindNext, etc.
but how?
anone can help me?
how to use findfirst, etc. ?
3 posts
>To search for files with a extension and in a certain folder, use (example):
$0 is the handle, don't change it until FindClose.
"${NSISDIR}\Examples\*.nsi" is where and what files want to search for.
>To confirm if the returned file is really a file, use (example):
>To detect the next file with "*.nsi" use (example):
>To end the detection use (example):
FindFirst $0 $1 "${NSISDIR}\Examples\*.nsi"Will return to $1 the first file found with *.nsi extension.$0 is the handle, don't change it until FindClose.
"${NSISDIR}\Examples\*.nsi" is where and what files want to search for.
>To confirm if the returned file is really a file, use (example):
IfFileExists "${NSISDIR}\$1\*.*" IsDir IsFile
IsDir: ;If the file is a dir, will execute this code below
SetErrors
IsFile: ;Returning to normal code(The example shows that will set errors each time a file is really a folder.)>To detect the next file with "*.nsi" use (example):
Will return to $1 the next file found with *.nsi extension.FindNext $0 $1
>To end the detection use (example):
FindClose $0
thx!