Archive: Help!


Help!
I think NSIS can do this, but I've been playing with it on and off for a few days now and I've gotten nowhere.

My installer needs to locate one EXE from the end user's computer and copy it to $INSTDIR. Their EXE could be anywhere on Drive C.

If my installer doesn't find the EXE in one folder, I need it to check other folders on the hard drive recursively until it finds one. If it still can't find one, my installer will force them to download the web packages that contains the correct EXE.

If my installer finds the EXE, I need to check it with the MD5 plugin for NSIS to ensure that it is the official EXE that I am looking for.

If it fails the MD5, it should keep looking for the correct EXE in other folders. If all of the EXE's fail MD5, my installer will force them to download the web package that contains the correct EXE.

If it passes the MD5, I need to break out of the find loop, copy their file and continue my installer.

It sure would be nice to have a browse button to allow end users to manually select a file that needs to be included.

Is any of this feasible?

Thanks,


You can use InstallOptions to 'Browse' to select the exe file, but there is no Search function in NSIS yet.

It could be done with FindFirst / FindNext, I shall have a look.

-Stu


FindFirst, FindNext and FindClose are the search function in NSIS. You do not need anything else.


i tried findfirst, findnext and findclose based on an example kichik sent the other day, but i didn't have any luck with it... it never found the exe or showed me a path. maybe i'm doing it wrong. examples are limited for these commands. :/

i can play with installoptions, it's all new to me... but if they cancel out of the browse function, will i still be able force the web package to download? and then if they install the other package, can i call installoptions again? i'm reading the help file now.

i think i would prefer to use findfirst, findnext and findclose.