views:

124

answers:

2

I'm looking at the Microsoft article for Operating System Property Values and it seems that both Windows Server 2008 R2 and Windows 7 have a VersionNT value of 601. I see in the comments on the article that you should use MsiNTProductType to differentiate the two.

So if I wanted to only allow server 2008 R2 installations (and not Windows 7), then would this be the correct condition:

MsiNTProductType > 1 AND VersionNT = 601

This would allow me any Windows 2008 R2 PC that is a domain controller or a server (Which Windows 7 is not?)

+1  A: 

I just built a MSI installer with that launch condition and that will indeed work just fine.

Kev
Awesome thanks! I would have tried it myself, but I do not have a 2k7 OS setup ATM.
Zenox
+1  A: 

To prevent failing in the future you should use:

MsiNTProductType > 1 AND VersionNT >= 601

This means your condition will still install on yet-to-be-developed versions of Windows Server. Note that >= is required if you are putting your software forward for logo testing.

sascha
Thanks for the tip. I generally do not allow the more generic version, as you never know what functionality new version may deprecate.
Zenox

related questions