Sky_MH
11th December 2006 13:23 UTC
creating custom Pages
Hi,
I am a newbie in Scripting and i need some advise in creating of custom pages. I have to write an installer for remote installation (patching some files). To ask the user for Information where to patch the files and so on, iwant to create some custom pages. But i don't know how i can create. I have read the user manual of NSIS and i have try to use the NIS Editor, but nothing helps.
Can anybody help me to solve the problem?
Thank you very much
Red Wine
11th December 2006 13:38 UTC
Well, first take a look at the included InstallOptions examples.
"Playing" with those examples would help understand dealing with custom pages.
zbd
12th December 2006 01:31 UTC
First in HM NIS EDIT make a new InstallOptions file (ini)
And just make a text box or something to display then save it in same dir as ur nsi script.
Where your pages are, put:
Page custom NamePageHere
then you need to make a function with the same page name
Function NamePageHere
!insertmacro MUI_HEADER_TEXT "$(NAMEPAGEHERE_TITLE)" "$(NAMEPAGEHERE_SUBTITLE)"
# Display the page.
!insertmacro MUI_INSTALLOPTIONS_DISPLAY "NamePageHere"
FunctionEnd
Now in the .onInit function near the bottom, put this:
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "ini_file.ini" "NamePageHere"
I spose once u work out how to display the page, then you can think about how to get values back from it
Zbd
Sky_MH
14th December 2006 15:26 UTC
creating custom pages
Hi,
I have tried to play with the examples and i can display the dialog but the window, where the dialog is display, is too small. I search in the user manual for help but i figure out that the command installoptions an extern command from a DLL is. Know anybody where I can find more information about these commands.
thanks
MH
Red Wine
14th December 2006 15:38 UTC
What do you mean too small? It's being either a window for classic UI or MUI. There is InstallOptions documentation within NSIS installation inside Docs folder.
Sky_MH
14th December 2006 17:26 UTC
small dialog
my custom dialog is greator than the dialog which is display on my screen.
Red Wine
14th December 2006 17:49 UTC
I guess you mean your control is bigger than the custom page window, or I'm completely confused?
You're free to manipulate your control the way you like (width, heigh and position).
Take a look here http://forums.winamp.com/showthread....hreadid=261562 there is a working example you may use it as a starting point.
Sky_MH
14th December 2006 17:54 UTC
thanks