David.Tooley
15th February 2009 22:55 UTC
Multiple specified directiories
Hi, I am trying to simplify one of our installations by pushing 2 app installers into 1.
the only thing stopping me is the fact that i cannot seem to figure out how to set 2 or more MUI_PAGE_DIRECTORY uses.
Example
App1 and App2 combined into one installer... i want to set App1 to a custom location and also App2 to a different location, both different than each other and different to the default install dir.
Currently I get the 1 MUI_PAGE_DIRECTORY page and it allows me to choose a different folder which will then install App1 and App2 inside.
Please if someone could help or share some advice, i would appreciate it.
Thanks
David
Animaether
15th February 2009 23:51 UTC
Just use 2 MUI_PAGE_DIRECTORY entries, and specify a different variable (using !define MUI_DIRECTORYPAGE_VARIABLE) to hold the directory picked for each of your two components.
e.g.
var InstDirOne
!define MUI_DIRECTORYPAGE_VARIABLE $InstDirOne
!insertmacro MUI_PAGE_DIRECTORY
var InstDirTwo
!define MUI_DIRECTORYPAGE_VARIABLE $InstDirTwo
!insertmacro MUI_PAGE_DIRECTORY
Make sure you use those variables in your components instead of $INSTDIR
Animaether
16th February 2009 00:24 UTC
oh.. just to add - if you would rather have 2 directory fields on 1 page, you'll have to create a custom page yourself using e.g. nsDialogs or the older InstallOptions(2/Ex)
David.Tooley
16th February 2009 00:39 UTC
Thanks heaps, i'm giving it a try now... its looking good so far..
Thanks
David