detect iis 5, iis 6 and iis7

Mar 2, 2011 at 11:33 AM

I want use Tasks (or Targets) in my Msbuild targets for detect IIS version (IIS 5 in XP,IIS 6 in Win2003, IIS 7 in W2008).

how can I get the version of IIS (or OS) using Msbuild extension pack ??

thx

 

 

Mar 2, 2011 at 8:37 PM

In our build scripts, we use a property that pulls the version from the registry, like so:

<IISVersion>$(registry:HKEY_LOCAL_MACHINE\Software\Microsoft\InetStp@MajorVersion)</IISVersion>

You can then test of $(IISVersion) is equal to 5, 6, or 7.

Mar 3, 2011 at 9:15 AM
Edited Mar 3, 2011 at 9:16 AM

 

Thanks mister. build script there aren't in download pack ??

Coordinator
Apr 4, 2011 at 8:54 PM

alhambraeidos, is this resolved for you now?