Defcon0
28th May 2007 10:55 UTC
Show an InstallOptions-Screen only when the OS is NT
Hello,
I have a question concerning InstallOptions.
Is there any way to avoid an InstallOptions-Screen from being shown if the used OS isn't NT ?
This is how I, at the time, check if the user has Win9x:
ClearErrors
UserInfo::GetName
IfErrors Win9x
...
Thanks in forward.
Bye Defcon0
Afrow UK
28th May 2007 12:19 UTC
If you're only using the UserInfo plugin to get the operating system then it'd be better to use the GetWindowsVersion function.
As for not displaying the page, just jump over the InstallOptions call or call Abort before displaying it.
Stu
Defcon0
28th May 2007 13:30 UTC
Thanks a lot ! It now works.
kichik
30th May 2007 20:19 UTC
The preferred method is the new WinVer.nsh.
!include LogicLib.nsh
!include WinVer.nsh
#...
${If} ${IsNT}
# nt here...
${Else}
# not nt
${EndIf}