Aaskilde
30th December 2011 11:51 UTC
Open link when pressing Finish?
Hi,
I need to make my installer so that when you press finish after the installation it opens a website, right now i have a checkbox but it should always open the site, so is there a way to grey out the checkbox so they cant tick it off or is there a way to make the installer so when they press finish the website will open?
//Aaskilde
Afrow UK
30th December 2011 17:51 UTC
Add a page leave function and open the website with ExecShell open.
Stu
Anders
30th December 2011 18:13 UTC
The finish page is not supposed to work that way IMHO, any action on it should be optional (Don't pull an Adobe please (Flash installer opens a URL without asking))
Aaskilde
9th January 2012 09:52 UTC
Afrow, when i need to call the leave-function i use the !define MUI_PAGE_CUSTOMFUNCTION_LEAVE? And how do i write it so that when you press the finish key the function ExecShell will be used to call the site?
Anders, it should not be optional in this case. The reason for that is the it opens contains the information in how to get the product working so they need the page.
Afrow UK
9th January 2012 11:15 UTC
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE FinishPageLeave
!insertmacro MUI_PAGE_FINISH
...
Function FinishPageLeave
ExecShell open ...
FunctionEnd
Stu
Aaskilde
16th January 2012 09:27 UTC
Hi Stu,
I have tried your code, but i still just get the website shown when i press the first next, her is a part of my code:
!define MUI_ICON "neodashboard.ico"
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE FinishPageLeave
;Interface Pages
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "Program License Agreement.rtf"
!insertmacro MUI_PAGE_DIRECTORY
Page custom InstallDirectory
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_LANGUAGE "English"
Function FinishPageLeave
ExecShell "open" "http://nsis.sf.net/"
FunctionEnd
Afrow UK
16th January 2012 12:45 UTC
There's no "FINISHPAGE" in the MUI_PAGE_CUSTOMFUNCTION_LEAVE define. This should tell you it's a generic define for each page. In other words, you define it before the page you are setting it for. The readme demonstrates this clearly.
Stu