Archive: InstallOption Reload


InstallOption Reload
Is there some way I can reload a page with InstallOption? I tried to use call the dll again, but it seems that after a InstallOption::dialog instruction, every other thing it's ignored...


What do you mean by "reload"? Do you mean like update the contents or controls?


Once the page is shown, you can't refresh it. You may only change what's in the controls in the pre function for a page. You could leave a page in the callback post function and then have a switch in the next pages pre function to go back to the previous page to get a pseudo-refresh action.


If you need to modify controls on the dialog you must use GetDlgItem then instructions like SendMessage, SetCtlColors, EnableWindow, ShowWindow etc
Changes to the INI file will not be shown on the dialog because at this time the dialog is in memory.

-Stu


Basically I need to add a item to the list of a DropList; I searched by I coudn't find any message to do this, so I was trying to modify the ini of the page, then reload it, but this seems impossible...


Hi mrbean87!

A possible solution is to go to the next page and in the preFunction of that page use sendmessage to go one page back. This will reload the page.

http://nsis.sourceforge.net/Go_to_a_NSIS_page
http://forums.winamp.com/showthread....ndmessage+page

Have a nice day!

-Bruno.


bholliger, you're a genius! It works great! Thanks a lot :)


Thanks! I'm glad to hear that it works!

-Bruno.


That would be a bad way to go about it as it would require the page to be unloaded and then reloaded into memory.

A much much faster way to do this is by using the CB_ADDSTRING message:
http://forums.winamp.com/showthread....t=CB_ADDSTRING

-Stu