cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
sharon
Level 5

SYSINFO.WINNT.nServicePack fails on WIN SERVER 2008 R2

Hi all,

Using basic MSI, I need to enable installation only if the OS is 64 bit, WIN SERVER 2008 R2 SP1.
I successfully use this code to detect WIN SERVER 2008 R2 on 64 bit:

if (svVersionNT64 =="601") then// 64 BIT, win server 2008 R2 or WIN7
if (!(SYSINFO.nOSProductType == VER_NT_WORKSTATION)) then //server

but when I debug this: if (SYSINFO.WINNT.nServicePack >= 1)
I get false value, although the target machine has SP1 installed.

Any suggestions for checking the SP value correctly on WIN SERVER 2008 R2?

Thanks!
Sharon.
Labels (1)
0 Kudos

(1) Reply
TsungH
Level 12

With a Basic MSI project, one could set up a launch condition with the following condition to detect Windows Server 2008 R2 SP1.
VersionNT = 601 AND MsiNTProductType = 3 AND ServicePackLevel = 1
For more info, please refer to Operating System Property Values.
0 Kudos