Skip to content
⌘ NSIS Forum Archive

Reuse nsDialogs

5 posts

xbarns#

Reuse nsDialogs

I have to gather some information from a user, in this case the path to some operating system files and other information. All in all i have to do this between 0 and 5 times.

I am wondering if i can reuse nsDialog forms and only slightly changing some labels (design stays the same).

Any Ideas?

Thanks in advance.
xbarns#
Would i then call the page 5 times? like this?

Page custom GetOSDetails LeaveGetOSDetails
Page custom GetOSDetails LeaveGetOSDetails
Page custom GetOSDetails LeaveGetOSDetails
Page custom GetOSDetails LeaveGetOSDetails
Page custom GetOSDetails LeaveGetOSDetails
Page custom GetOSDetails LeaveGetOSDetails

Or would i only call it once and once i am at the "end" of the dialog i check if i need to "goto thetop" another time? Will that call the "Leave" function every time?

Thanks for the help!
Yathosho#
calling the page once should do the job, have a look at nsDialog's onClick/onChange functions. i'd also suggest you indicate the progress by changing a label - otherwise the user might think he's doing something wrong
xbarns#
Thanks, i now use a seperate Function that i call into. And yes i have thought of changing the label so noone gets confused.

😁