Local/network installation of .exe/.bat/manual
Hello,

I downloaded NSIS installer and I'd like to use it to create an installer. I studied manual, scripting language; the page/section architecture seems me clear. But the program to be installed is a Windows console application and has several special features.

The program package consists of the main executable (.exe), a batch file (.bat which runs the selected file with the executable) and the manual directory.

1) In most cases, the program will be placed on a shared location (e.g. network drive). So the first step of the installation should be selection of type of installation - "Local" (simply "LocInst") (all mentioned files will be copied on a local drive) or "Shared" (simply "ShInst") (only the .bat will be copied to the local drive). The first question is how the .nsi input scripting file shoud look to allow user to select "LocInst" or "ShInst" (maybe a simple dialog with 2 radio buttons will appear).

2) When "ShInst" is selected, I need to allow user to enter path to the main executable. How via script to "pre-fill" the edit box where the path is to be entered? I would need to scan all drives and try to locate <DRIVE>\...\PROGRAM.exe. And - if the .exe is found - to fill in the edit box where the user is about to enter the path. - And how - via script - to check the path entered is correct and the .exe exists?

3) In both - "LocInst" and "ShInst" - installation modes the user will be prompted to select the .bat file location. Similarly as in the previous step, I would like the installator to try to find a special directory. Existence of directories should be tried in the order: C:\Bat -> C:\<USER_NAME>\Bat -> (... several more). How to - via script - to find the first directory that exists?

4) The common step in both installation modes is to associate an extension (e.g. .prg) with the copied .bat file. How to do it?

Thanks.

LuP