After install success I need to show the popup with checkbox if checkbox selected open the app otherwise cancel app.
this is my installer.nsh file
!include “MUI2.nsh”
Function GetWindowsVersion
ReadRegStr $0 HKLM “SOFTWAREMicrosoftWindows NTCurrentVersion” CurrentMajorVersionNumber
StrCpy $1 $0
FunctionEnd
!define MUI_WELCOMEPAGE_TITLE “Welcome to MammoQC Installation”
!define MUI_WELCOMEPAGE_TEXT
“This wizard will guide you through the installation process.$n$n
Minimum installation requirements:$n$n
- System should have minimum 500MB space in installation Drive.$n
- System should have minimum 300MB RAM.”
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
Section
Call GetWindowsVersion
Pop $0 ; Get the result of GetWindowsVersion function
; Check if the Windows version is 10 or 11
StrCmp $0 "10" 0 check_version
StrCmp $0 "11" 0 check_version
Goto abort_installation
check_version:
Goto installation_done
abort_installation:
; If the version is not 10 or 11, abort the installation
MessageBox MB_ICONEXCLAMATION|MB_OK “This software requires Windows 10 or 11 to run. Your current Windows version: $0”
Abort
installation_done:
SectionEnd
After install success I need to show the popup with checkbox if checkbox selected open the app otherwise cancel app.
parandhaman k is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.