Archive: manipulate custom pages on run-time


manipulate custom pages on run-time
Hello,

my situation is as follows: I have some ini file which contains a text. This text should be displayed in a custom page.

How do I do that?

thanks a lot!

Jakob, from Leipzig, Germany


Look at ${NSISDIR}\Contrib\InstallOptionsEx\Docs\Readme.html


You won't have InstallOptionsEx installed, so you should look at NSIS\Docs\InstallOptions\Readme.html instead.

-Stu


Hello,

thanks for the quick responses. I'm sorry to bother you again. I'm quite new to these things.

I understand the documentation how to collect the users input from the custom form. But I wish to change the layout of the custom form at run-time.

It seems to me that this requires a dynamic creation of the ini file which is responsible for the custom form. Or is there any possibility to change the content of a label for instance on run-time?

Thank you very much!

Jakob


Yeah, before you load the ini file for a custom page (with InstallOptions::initDialog), just do a WriteINIStr to the field you want.


Function CustomPre
WriteINIStr "myfile.ini" "Field 1" "Text" "New Text"

InstallOptions::initDialog
Pop $R0
FunctionEnd

With an INI file of

[Settings]
NumFields=1
[Field 1]
Type=Label
Text=bla
...