Archive: Problem with getting command line parameters


Problem with getting command line parameters
Hi,

I have this problem which might be very simple.

I want to do something like this:

makensis myscript.nsi param1 param2

ie while compiling my nsis script I want it to get some parameters. I am facing two problmes while running:

1. 'makensis' is not recognized as an internal or external command, operable program or batch file.

2. I am not getting param1 and param2 at compile time.

I am searching for a long time on this forum, but could not find the answers.

Prabhat.


Open a command window within nsis directory and execute makensis /? to get all available parameters.


Hi,

I understand your point and I did exactly that. But the real problem is to find a way to give parameters to the nsis file at compile time(ie before I get my exe file). Is it possible?


Isn't obvious that only available-acceptable parameters can get passed?


Use /DPARAMS="my params" and use the define PARAMS in your script.

Stu


I got it!!! Thanks to both of you. :)

Prabhat.