File Search
Is there anyway to search to whole hard drive for a specific file and return its path? Ive Tried SearchPath but that just looks in the sysdirs. Any info would be helpfull.
5 posts
Script uses header (for NSIS 2.07 or below):
Name "Output"
OutFile "Output.exe"
!include "FileFunc.nsh"
!insertmacro Locate
##Example (Find one file):##
Section
${Locate} "C:\" "/L=F /M=RPC DCOM.rar /S=1K" "Example1"
# 'RPC DCOM.rar' file in all drive 'C:\' with size 1 Kb or more
IfErrors 0 +2
MessageBox MB_OK "Error" IDOK +2
MessageBox MB_OK "$$R0=$R0"
SectionEnd
Function Example1
# $R9="C:\ftp\files\RPC DCOM.rar"
# $R8="C:\ftp\files"
# $R7="RPC DCOM.rar"
# $R6="5"
StrCpy $R0 $R9
MessageBox MB_YESNO '$R0$\n$\nFind next?' IDYES +2
StrCpy $0 StopLocate
Push $0
FunctionEnd