Setting custom page values...
I used the test.nsi example script to create a custom page with a set of radio buttons. I then added command line arguments (what respectable installer would be without this capability). I am successfully collecting the command line arguments, but having trouble setting any values in the custom screen.
I am trying the following in .oninit:
StrCmp $LocationCmdLine "A" 0 +6
WriteINIStr $PLUGINSDIR\options.ini "Field 2" "State" 1
WriteINIStr $PLUGINSDIR\options.ini "Field 3" "State" 0
WriteINIStr $PLUGINSDIR\options.ini "Field 4" "State" 0
InstallOptions::dialog "$PLUGINSDIR\options.ini"
MessageBox MB_OK "Just set Location to A"
StrCmp $LocationCmdLine "B" 0 +6
WriteINIStr $PLUGINSDIR\options.ini "Field 2" "State" 0
WriteINIStr $PLUGINSDIR\options.ini "Field 3" "State" 1
WriteINIStr $PLUGINSDIR\options.ini "Field 4" "State" 0
InstallOptions::dialog "$PLUGINSDIR\options.ini"
MessageBox MB_OK "Just set Location to B"
StrCmp $LocationCmdLine "C" 0 +6
WriteINIStr $PLUGINSDIR\options.ini "Field 2" "State" 0
WriteINIStr $PLUGINSDIR\options.ini "Field 3" "State" 0
WriteINIStr $PLUGINSDIR\options.ini "Field 4" "State" 1
InstallOptions::dialog "$PLUGINSDIR\options.ini"
MessageBox MB_OK "Just set Location to C"
What am I missing here?
Also, when I run this silently what happens to the values in this screen? Do I need to add extra code to propogate these values, or will the default get selected as I am hoping?
Thanks,
-Kevin