Archive: Button Question


Button Question
Hello,

I have a custom page, that is set on a mypage.ini file, it has 4 buttoms and each one of this buttons calls the same installer with one diferent parameters, on my custompage.ini had 4 button fields like this:

[Field 7]
Type=Button
Text=INSTALL 0
Flags=NOTABSTOP
State=Installer\setup.exe 0
Left=254
Right=304
Top=65
Bottom=75

[Field 8]
Type=Button
Text=INSTALL 1
Flags=NOTABSTOP
State=Installer\setup.exe 1
Left=254
Right=304
Top=65
Bottom=75
[Field 9]

Type=Button
Text=INSTALL 2
Flags=NOTABSTOP
State=Installer\setup.exe 2
Left=254
Right=304
Top=65
Bottom=75
[Field 10]

Type=Button
Text=INSTALL 3
Flags=NOTABSTOP
State=Installer\setup.exe 3
Left=254
Right=304
Top=65
Bottom=75


but it does not work, if i use:
State=Installer\setup.exe
without the parameter it works fine, but no parameters is set, is there anyway to make the .ini file to accept command lines with parameters?


Did you try with quotes?

Also did you try to grab the state on custom page leave function and pass an Exec or ExecWait instead?


yes, i tryed quotes and the custom page does not have a leave function, because it must stay open so the user can chose what to install, until the user close it =/


Add abort on leave function if you want to stay on the page.

For instance, you could grab which is pressed, pass Exec or ExecWait and then abort to stay on the page.


sorry about the dumb question, but how do i do it?


Take a look at the included example testnotify.nsi, once you know which control is pressed, you can do anything that you like and stay on the page if you prefer awaiting another action.


thank you! it worked =D