VERSION 1.0 CLASS
BEGIN
  MultiUse = -1  'True
  Persistable = 0  'NotPersistable
  DataBindingBehavior = 0  'vbNone
  DataSourceBehavior  = 0  'vbNone
  MTSTransactionMode  = 0  'NotAnMTSObject
END
Attribute VB_Name = "cOperSystem"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = False
Attribute VB_Ext_KEY = "SavedWithClassBuilder6" ,"Yes"
Attribute VB_Ext_KEY = "Top_Level" ,"Yes"
' ***************************************************************************
'  Module:        clsOperSystem
'
'  Description:   Determines the operating system.  When this class is
'                 initialized, the GetWindowsVersion() routine is called.
'                 This will instantly set the flags to their appropriate
'                 value.  This module does not test with operating sytems
'                 earlier than Windows NT4.
'
'                 Identifying the current operating system is usually not
'                 the best way to determine whether a particular operating
'                 system feature is present. This is because the operating
'                 system may have had new features added in a redistributable
'                 DLL. Rather than using GetVersionEx to determine the
'                 operating system platform or version number, test for the
'                 presence of the feature itself.
'                 http://msdn.microsoft.com/en-us/library/ms724832(VS.85).aspx
'
' Important:      This module must have access to modTrimStr.bas
'
' -----------------------------------------------------------------------
' The base version information for various Windows versions is:
'
' Version                     Number  Major  Minor  Other info
' -----------------------------------------------------------------------
' Windows 8                    ?.?      ?      ?    Official release due in Fall of 2012
' Windows 7                    6.1      6      1    OSVERIONINFOEX.wProductType = VER_NT_WORKSTATION
' Windows Server 2008 R2       6.1      6      1    OSVERIONINFOEX.wProductType <> VER_NT_WORKSTATION
' Windows Server 2008          6.0      6      0    OSVERSIONINFOEX.wProductType <> VER_NT_WORKSTATION
' Windows Vista                6.0      6      0    OSVERSIONINFOEX.wProductType = VER_NT_WORKSTATION
' Windows Server 2003 R2       5.2      5      2    GetSystemMetrics(SM_SERVERR2) <> 0
' Windows Server 2003          5.2      5      2    GetSystemMetrics(SM_SERVERR2) = 0
' Windows Home Server          5.2      5      2    OSVERSIONINFOEX.wSuiteMask = VER_SUITE_WH_SERVER
' Windows XP Pro x64 Edition   5.2      5      2    (OSVERSIONINFOEX.wProductType = VER_NT_WORKSTATION) And
'                                                   (SYSTEM_INFO.wProcessorArchitecture = PROCESSOR_ARCHITECTURE_AMD64)
' Windows XP                   5.1      5      1
' Windows 2000                 5.0      5      0
' Windows NT4                  4.0      4      0
' -----------------------------------------------------------------------
'
' Reference:   Randy Birch
'              GetVersionEx: Windows Version Info (Wrapper Routines)
'              http://vbnet.mvps.org/code/helpers/iswinversion.htm
'
'              Karl Perterson's Classic VB
'              http://www.mvps.org/vb/
'
'              GetVersionEx Function
'              http://msdn2.microsoft.com/en-us/library/ms724451(VS.85).aspx
'
'              Getting the System Version (Source code)
'              http://msdn2.microsoft.com/en-us/library/ms724429(VS.85).aspx
'
'              Operating System Version
'              http://msdn.microsoft.com/en-us/library/windows/desktop/ms724832%28v=vs.85%29.aspx
'              
'              OSVersionInfoEx Structure
'              http://msdn2.microsoft.com/en-us/library/ms724833(VS.85).aspx
'
'              GetSystemMetrics Function
'              http://msdn2.microsoft.com/en-us/library/ms724385(VS.85).aspx
'
'              GetSystemInfo Function
'              http://msdn2.microsoft.com/en-us/library/ms724381(VS.85).aspx
'
'              GetProductInfo Function
'              http://msdn2.microsoft.com/en-us/library/ms724358.aspx
'
' Important:   Developers working in the Windows Vista environment should be
'              aware that if this code is run in the VB IDE and you are
'              notified that the operating system is other than Windows Vista,
'              do the following:
'
'              1.  Close the VB IDE (Visual BASIC Integrated Development Environment)
'              2.  Locate the file VB.EXE
'              3.  Right mouse click and select Properties >> Compatibility tab
'              4.  Remove any checkmarks and close the window
'              5.  Restart the VB IDE
'
'  -----------------------------------------------------------------------
'
'  Example:    Set objOS = new cOperSystem  ' Instantiate class object
'
'              ' Is this Windows XP?
'              If objOS.bWinXP then
'                  Msgbox objOS.VersionName & vbNewLine & _
'                          "Version " & objOS.VersionNumber & " " & _
'                          objOS.ServicePack
'              Else
'                  Msgbox "This is not Windows XP"
'              End If
'
'              Set objOS = Nothing  ' Free class object from memory
'
' ===========================================================================
'    DATE      NAME / eMAIL
'              DESCRIPTION
' -----------  --------------------------------------------------------------
' 15-Oct-2006  Kenneth Ives  kenaso@tx.rr.com
'              Converted to a class, renamed some of the variables,
'              Combined some of the routines for speed.  When this class is
'              initialized, the GetWindowsVersion() routine is called.  This
'              will instantly set the flags to their appropriate value.
' 16-Jan-2008  Kenneth Ives  kenaso@tx.rr.com
'              Dropped support for any operating systems earlier than Windows
'              NT4 Servers and Windows 2000.
' 17-Apr-2008  Kenneth Ives  kenaso@tx.rr.com
'              Updated for additional Windows Vista versions.
'              Updated 64-bit testing routines.
' 30-Jul-2008  Kenneth Ives  kenaso@tx.rr.com
'              Updated for Windows 2000 Data Center Server
' 20-Aug-2008  Kenneth Ives  kenaso@tx.rr.com
'              Updated testing logic for enhanced systems
' 04-May-2009  Kenneth Ives  kenaso@tx.rr.com
'              Rewrote module.
'              Added testing for additional Windows operating systems.
' 05-Sep-2009  Kenneth Ives  kenaso@tx.rr.com
'              Thanks to Maria AAM for pointing out that I needed to add an
'              additional property named bOperSystem64() denoting a 64-bit
'              operating system in general
' 20-Jul-2011  Kenneth Ives  kenaso@tx.rr.com
'              - Updated logic in TestForOldestVersion() routine
'              - Added property bWinXPSP3() for Windows XP Service Pack 3
'              - Updated IsWinXP() routine
'              - Updated TestForOtherServers() routine
' 26-Mar-2012  Kenneth Ives  kenaso@tx.rr.com
'              - Deleted RemoveTrailingNulls() routine from this module. 
'              - Changed call to RemoveTrailingNulls() to TrimStr module 
'                due to speed and accuracy.
'              - Updated TestForOldestVersion() routine logic.
' ***************************************************************************
Option Explicit

' ***************************************************************************
' Constants
' ***************************************************************************
  ' used by OSVERSIONINFOEX.PlatformID
  Private Const VER_PLATFORM_WIN32_NT                As Long = 2

  ' used by OSVERSIONINFOEX.wProductType
  Private Const VER_NT_WORKSTATION                   As Long = &H1     ' Windows Vista, XP Pro, XP Home Edition, or 2000 Pro
  Private Const VER_NT_DOMAIN_CONTROLLER             As Long = &H2     ' Windows Server 2008, Windows Server 2003, or Windows 2000 Server
  Private Const VER_NT_SERVER                        As Long = &H3     ' Windows Server 2008, Windows Server 2003, or Windows 2000 Server

  ' used by OSVERSIONINFOEX.wSuiteMask
  Private Const VER_SUITE_SMALLBUSINESS              As Long = &H1     ' Microsoft Small Business Server w        As once installed on the system, but may have been upgraded to another version of Windows
  Private Const VER_SUITE_ENTERPRISE                 As Long = &H2     ' Windows Server 2008 Enterprise, Windows Server 2003, Enterprise Edition, or Windows 2000 Advanced Server is installed
  Private Const VER_SUITE_BACKOFFICE                 As Long = &H4     ' Windows backoffice suite
  Private Const VER_SUITE_TERMINAL                   As Long = &H10    ' Terminal Services is installed
  Private Const VER_SUITE_EMBEDDEDNT                 As Long = &H40    ' Windows XP Embedded is installed
  Private Const VER_SUITE_DATACENTER                 As Long = &H80    ' Windows Server 2008 Datacenter, Windows Server 2003, Datacenter Edition, or Windows 2000 Datacenter Server is installed
  Private Const VER_SUITE_PERSONAL                   As Long = &H200   ' Windows Vista Home Premium, Windows Vista Home Basic, or Windows XP Home Edition is installed
  Private Const VER_SUITE_BLADE                      As Long = &H400   ' Windows Server 2003, Web Edition is installed
  Private Const VER_SUITE_STORAGE_SERVER             As Long = &H2000  ' Windows Storage Server 2003 R2 or Windows Storage Server 2003 is installed
  Private Const VER_SUITE_COMPUTE_SERVER             As Long = &H4000  ' Windows Server 2003, Compute Cluster Edition is installed
  Private Const VER_SUITE_WH_SERVER                  As Long = &H8000  ' Windows home server is installed
  Private Const VER_SUITE_SMALLBUSINESS_RESTRICTED   As Long = &H20    ' Microsoft Small Business Server is installed with the restrictive client license in force

  Private Const SM_TABLETPC                          As Long = 86
  Private Const SM_MEDIACENTER                       As Long = 87
  Private Const SM_STARTER                           As Long = 88
  Private Const SM_SERVERR2                          As Long = 89

  Private Const PROCESSOR_ARCHITECTURE_INTEL         As Long = 0       ' 32-bit
  Private Const PROCESSOR_ARCHITECTURE_IA64          As Long = 6       ' 64-bit
  Private Const PROCESSOR_ARCHITECTURE_AMD64         As Long = 9       ' 64-bit

  ' GetProductInfo possible values
  Private Const PRODUCT_ULTIMATE                     As Long = &H1     ' Ultimate Edition
  Private Const PRODUCT_HOME_BASIC                   As Long = &H2     ' Home Basic Edition
  Private Const PRODUCT_HOME_PREMIUM                 As Long = &H3     ' Home Premium Edition
  Private Const PRODUCT_ENTERPRISE                   As Long = &H4     ' Enterprise Edition
  Private Const PRODUCT_HOME_BASIC_N                 As Long = &H5     ' Home Basic Edition
  Private Const PRODUCT_BUSINESS                     As Long = &H6     ' Business Edition
  Private Const PRODUCT_STANDARD_SERVER              As Long = &H7     ' Server Standard Edition (full installation)
  Private Const PRODUCT_DATACENTER_SERVER            As Long = &H8     ' Server Datacenter Edition (full installation)
  Private Const PRODUCT_SMALLBUSINESS_SERVER         As Long = &H9     ' Small Business Server
  Private Const PRODUCT_ENTERPRISE_SERVER            As Long = &HA     ' Server Enterprise Edition (full installation)
  Private Const PRODUCT_STARTER                      As Long = &HB     ' Starter Edition
  Private Const PRODUCT_DATACENTER_SERVER_CORE       As Long = &HC     ' Server Datacenter Edition (core installation)
  Private Const PRODUCT_STANDARD_SERVER_CORE         As Long = &HD     ' Server Standard Edition (core installation)
  Private Const PRODUCT_ENTERPRISE_SERVER_CORE       As Long = &HE     ' Server Enterprise Edition (core installation)
  Private Const PRODUCT_ENTERPRISE_SERVER_IA64       As Long = &HF     ' Server Enterprise Edition for Itanium-based Systems
  Private Const PRODUCT_BUSINESS_N                   As Long = &H10    ' Business Edition
  Private Const PRODUCT_WEB_SERVER                   As Long = &H11    ' Web Server Edition (full installation)
  Private Const PRODUCT_CLUSTER_SERVER               As Long = &H12    ' Cluster Server Edition
  Private Const PRODUCT_HOME_SERVER                  As Long = &H13    ' Home Server Edition
  Private Const PRODUCT_SMALLBUSINESS_SERVER_PREMIUM As Long = &H19    ' Small Business Server Premium Edition
  Private Const PRODUCT_HOME_PREMIUM_N               As Long = &H1A    ' Home Premium Edition
  Private Const PRODUCT_ENTERPRISE_N                 As Long = &H1B    ' Enterprise Edition
  Private Const PRODUCT_ULTIMATE_N                   As Long = &H1C    ' Ultimate Edition
   
' ***************************************************************************
' Type structures
' ***************************************************************************
  ' The OSVERSIONINFOEX data structure contains operating system version
  ' information. The information includes major and minor version numbers,
  ' a build number, a platform identifier, and information about product
  ' suites and the latest Service Pack installed on the system. This structure
  ' is used with the GetVersionEx and VerifyVersionInfo functions.
  Private Type OSVERSIONINFOEX
      OSVSize           As Long          ' size of this data structure (in bytes)
      dwVerMajor        As Long          ' ex: 5
      dwVerMinor        As Long          ' ex: 01
      dwBuildNumber     As Long          ' ex: 2600
      PlatformID        As Long          ' Identifies operating system platform
      szCSDVersion      As String * 128  ' ex: "Service Pack 3"
      wServicePackMajor As Integer
      wServicePackMinor As Integer
      wSuiteMask        As Integer
      wProductType      As Byte
      wReserved         As Byte
  End Type

  ' The SYSTEM_INFO structure contains information about the current computer
  ' system.  This includes the architecture and type of the processor, the
  ' number of processors in the system, the page size, and other such information.
  Private Type OEM_ID
      wProcessorArchitecture As Integer
      wReserved              As Integer
  End Type
  
  Private Type SYSTEM_INFO
      dwOemID                     As OEM_ID
      dwPageSize                  As Long
      lpMinimumApplicationAddress As Long
      lpMaximumApplicationAddress As Long
      dwActiveProcessorMask       As Long
      dwNumberOfProcessors        As Long
      dwProcessorType             As Long
      dwAllocationGranularity     As Long
      wProcessorLevel             As Integer
      wProcessorRevision          As Integer
  End Type

  ' Windows operating system formatted information
  Private Type OS_INFORMATION
      PlatformID   As Long
      VersionName  As String
      VersionNo    As String
      BuildNo      As String
      ServicePack  As String
  End Type

' ***************************************************************************
' API Declares
' ***************************************************************************
  ' This function obtains extended information about the version of the
  ' operating system that is currently running.
  Private Declare Function GetSystemMetrics Lib "user32" _
          (ByVal nIndex As Long) As Long

  ' This function obtains extended information about the version of the
  ' operating system that is currently running.  If the function succeeds,
  ' the return value is a nonzero value.
  Private Declare Function GetVersionEx Lib "kernel32" Alias "GetVersionExA" _
          (LpVersionInformation As Any) As Long

  ' The GetProcAddress function returns the address of the specified
  ' exported dynamic-link library (DLL) function. If the function call fails,
  ' the return value is null.
  Private Declare Function GetProcAddress Lib "kernel32" _
          (ByVal hModule As Long, ByVal lpProcName As String) As Long

  ' Retrieves a module handle for the specified module. The module must have
  ' been loaded by the calling process.
  Private Declare Function GetModuleHandle Lib "kernel32" Alias "GetModuleHandleA" _
         (ByVal lpModuleName As String) As Long
  
  ' This function returns information about the current system.
  Private Declare Sub GetSystemInfo Lib "kernel32" _
          (lpSystemInfo As SYSTEM_INFO)
  
  ' Retrieves information about the current system running Windows 2000 Pro or
  ' newer.  It is equivalent to the GetSystemInfo function.
  Private Declare Sub GetNativeSystemInfo Lib "kernel32" _
          (lpSystemInfo As SYSTEM_INFO)

  ' Retrieves the product type for the operating system on the local
  ' computer, and maps the type to the product types supported by the
  ' specified operating system.
  Private Declare Function GetProductInfo Lib "kernel32" _
          (ByVal dwOSMajorVersion As Long, ByVal dwOSMinorVersion As Long, _
          ByVal dwSpMajorVersion As Long, ByVal dwSpMinorVersion As Long, _
          pdwReturnedProductType As Long) As Long

  ' ZeroMemory is used for clearing the contents of a type structure.
  Private Declare Sub ZeroMemory Lib "kernel32" Alias "RtlZeroMemory" _
          (Destination As Any, ByVal Length As Long)

' ***************************************************************************
' Module Variables
'
'                    +-------------- Module level designator
'                    |  +----------- Data type (Boolean)
'                    |  |     |----- Variable subname
'                    - --- ---------
' Naming standard:   m bln WindowsNT
' Variable name:     mblnWindowsNT
'
' ***************************************************************************
  Private mtypOSInfo                        As OS_INFORMATION
  Private mtypOSVIEX                        As OSVERSIONINFOEX
  Private mtypSI                            As SYSTEM_INFO
  Private mstrVerName                       As String
  Private mstrSrvPack                       As String
  
  Private mblnWindowsNT                     As Boolean
  Private mblnWinNT4orNewer                 As Boolean
  Private mblnWin2000orNewer                As Boolean
  Private mblnWinXPorNewer                  As Boolean
  Private mblnWinVistaOrNewer               As Boolean
  
  Private mblnWin2000                       As Boolean
  Private mblnWin2000Pro                    As Boolean
  Private mblnWin2000Workstation            As Boolean
  Private mblnWin2000Server                 As Boolean
  Private mblnWin2000DatacenterSvr          As Boolean
  Private mblnWin2000AdvancedSvr            As Boolean
  
  Private mblnWinXP                         As Boolean
  Private mblnWinXPSP2                      As Boolean
  Private mblnWinXPSP3                      As Boolean
  Private mblnWinXPHomeEdition              As Boolean
  Private mblnWinXPPro                      As Boolean
  Private mblnWinXPMediaCenter              As Boolean
  Private mblnWinXPStarter                  As Boolean
  Private mblnWinXPTabletPC                 As Boolean
  Private mblnWinXPEmbedded                 As Boolean
  
  Private mblnWinVista                      As Boolean
  Private mblnWinVistaSP1                   As Boolean
  Private mblnWinVistaHomeBasic             As Boolean
  Private mblnWinVistaHomeEdition           As Boolean
  Private mblnWinVistaHomePremium           As Boolean
  Private mblnWinVistaHomeServer            As Boolean
  Private mblnWinVistaUltimate              As Boolean
  Private mblnWinVistaBusiness              As Boolean
  Private mblnWinVistaEnterprise            As Boolean
  Private mblnWinVistaWorkstation           As Boolean
  Private mblnWinVistaStarter               As Boolean
  Private mblnWindows7                      As Boolean
  
  Private mblnWinServer2003                 As Boolean
  Private mblnWin2003ServerR2               As Boolean
  Private mblnWin2003StorageServer          As Boolean
  Private mblnBladeServer                   As Boolean
  Private mblnWebServer                     As Boolean
  Private mblnWinHomeServer                 As Boolean
  Private mblnClusterServer                 As Boolean
  Private mblnComputeClusterServer          As Boolean
  Private mblnWinServer2008                 As Boolean
  Private mblnWinServer2008R2               As Boolean
  Private mblnDataCenterServer              As Boolean
  Private mblnDataCenterServerCore          As Boolean
  
  Private mblnBackOfficeServer              As Boolean
  Private mblnDomainController              As Boolean
  Private mblnEnterpriseServer              As Boolean
  Private mblnEnterpriseServerCore          As Boolean
  Private mblnTerminalServer                As Boolean
  Private mblnSmallBusinessServer           As Boolean
  Private mblnSmallBusinessServerPremium    As Boolean
  Private mblnSmallBusinessRestrictedServer As Boolean
  Private mblnStandardServer                As Boolean
  Private mblnStandardServerCore            As Boolean
  
  ' 64-Bit Versions
  Private mblnWinVista64                    As Boolean
  Private mblnWinXPPro64                    As Boolean
  Private mblnDataCenterItanium64           As Boolean
  Private mblnEnterpriseItanium64           As Boolean
  Private mblnDataCenter64                  As Boolean
  Private mblnEnterprise64                  As Boolean
  Private mblnStandard64                    As Boolean
  Private mblnComputeServer64               As Boolean
  Private mblnDatacenterServer64            As Boolean
  Private mblnEnterpriseServer64            As Boolean
  Private mblnWebBladeServer64              As Boolean
  Private mblnStandardServer64              As Boolean
  Private mblnOperSystem64                  As Boolean


' ***************************************************************************
' ****                      Properties                                   ****
' ***************************************************************************

Public Property Get VersionName() As String
    VersionName = mtypOSInfo.VersionName
End Property

Public Property Get VersionNumber() As String
    VersionNumber = mtypOSInfo.VersionNo
End Property

Public Property Get BuildNumber() As String
    BuildNumber = mtypOSInfo.BuildNo
End Property

Public Property Get VersionData() As String

    With mtypOSInfo
        VersionData = .VersionName & " " & _
                      .VersionNo & "." & _
                      .BuildNo
    End With
    
    If mblnWinNT4orNewer Then
        VersionData = VersionData & " " & ServicePack
    End If

End Property

Public Property Get ServicePack() As String
    ServicePack = mtypOSInfo.ServicePack
End Property

Public Property Get PlatformID() As Long
    PlatformID = mtypOSInfo.PlatformID
End Property

Public Property Get bWindowsNT() As Boolean
    bWindowsNT = mblnWindowsNT
End Property

Public Property Get bWinNT4orNewer() As Boolean
    bWinNT4orNewer = mblnWinNT4orNewer
End Property

Public Property Get bWin2000() As Boolean
    bWin2000 = mblnWin2000
End Property

Public Property Get bWin2000Pro() As Boolean
    bWin2000Pro = mblnWin2000Pro
End Property

Public Property Get bWin2000Workstation() As Boolean
    bWin2000Workstation = mblnWin2000Workstation
End Property

Public Property Get bWin2000Server() As Boolean
    bWin2000Server = mblnWin2000Server
End Property

Public Property Get bWin2000DatacenterSvr() As Boolean
    bWin2000DatacenterSvr = mblnWin2000DatacenterSvr
End Property

Public Property Get bWin2000AdvancedSvr() As Boolean
    bWin2000AdvancedSvr = mblnWin2000AdvancedSvr
End Property

Public Property Get bWin2000orNewer() As Boolean
    bWin2000orNewer = mblnWin2000orNewer
End Property

Public Property Get bWinXP() As Boolean
    bWinXP = mblnWinXP
End Property

Public Property Get bWinXPSP2() As Boolean
    bWinXPSP2 = mblnWinXPSP2
End Property

Public Property Get bWinXPSP3() As Boolean
    bWinXPSP3 = mblnWinXPSP3
End Property

Public Property Get bWinXPHomeEdition() As Boolean
    bWinXPHomeEdition = mblnWinXPHomeEdition
End Property

Public Property Get bWinXPProfessional() As Boolean
    bWinXPProfessional = mblnWinXPPro
End Property

Public Property Get bWinXPMediaCenter() As Boolean
    bWinXPMediaCenter = mblnWinXPMediaCenter
End Property

Public Property Get bWinXPStarter() As Boolean
    bWinXPStarter = mblnWinXPStarter
End Property

Public Property Get bWinXPTabletPC() As Boolean
    bWinXPTabletPC = mblnWinXPTabletPC
End Property

Public Property Get bWinXPEmbedded() As Boolean
    bWinXPEmbedded = mblnWinXPEmbedded
End Property

Public Property Get bWinXPorNewer() As Boolean
    bWinXPorNewer = mblnWinXPorNewer
End Property

Public Property Get bWindows7() As Boolean
    bWindows7 = mblnWindows7
End Property

Public Property Get bWinVistaStarter() As Boolean
    bWinVistaStarter = mblnWinVistaStarter
End Property

Public Property Get bWinServer2003() As Boolean
    bWinServer2003 = mblnWinServer2003
End Property

Public Property Get bWin2003ServerR2() As Boolean
    bWin2003ServerR2 = mblnWin2003ServerR2
End Property

Public Property Get bWin2003StorageServer() As Boolean
    bWin2003StorageServer = mblnWin2003StorageServer
End Property

Public Property Get bComputeClusterServer() As Boolean
    bComputeClusterServer = mblnComputeClusterServer
End Property

Public Property Get bWinVista() As Boolean
    bWinVista = mblnWinVista
End Property

Public Property Get bWinVistaSP1() As Boolean
    bWinVistaSP1 = mblnWinVistaSP1
End Property

Public Property Get bWinVistaHomeBasic() As Boolean
    bWinVistaHomeBasic = mblnWinVistaHomeBasic
End Property

Public Property Get bWinVistaHomeEdition() As Boolean
    bWinVistaHomeEdition = mblnWinVistaHomeEdition
End Property

Public Property Get bWinVistaHomePremium() As Boolean
    bWinVistaHomePremium = mblnWinVistaHomePremium
End Property

Public Property Get bWinVistaHomeServer() As Boolean
    bWinVistaHomeServer = mblnWinVistaHomeServer
End Property

Public Property Get bWinVistaUltimate() As Boolean
    bWinVistaUltimate = mblnWinVistaUltimate
End Property

Public Property Get bWinVistaBusiness() As Boolean
    bWinVistaBusiness = mblnWinVistaBusiness
End Property

Public Property Get bWinVistaEnterprise() As Boolean
    bWinVistaEnterprise = mblnWinVistaEnterprise
End Property

Public Property Get bWinVistaWorkstation() As Boolean
    bWinVistaWorkstation = mblnWinVistaWorkstation
End Property

Public Property Get bWinServer2008() As Boolean
    bWinServer2008 = mblnWinServer2008
End Property

Public Property Get bWinServer2008R2() As Boolean
    bWinServer2008R2 = mblnWinServer2008R2
End Property

Public Property Get bWinVistaOrNewer() As Boolean
    bWinVistaOrNewer = mblnWinVistaOrNewer
End Property

Public Property Get bDataCenterServer() As Boolean
    bDataCenterServer = mblnDataCenterServer
End Property

Public Property Get bDataCenterServerCore() As Boolean
    bDataCenterServerCore = mblnDataCenterServerCore
End Property

Public Property Get bBackOfficeServer() As Boolean
    bBackOfficeServer = mblnBackOfficeServer
End Property

Public Property Get bBladeServer() As Boolean
    bBladeServer = mblnBladeServer
End Property

Public Property Get bWebServer() As Boolean
    bW0AVoolean
    bComputeClusterServer = mblnComputeClusterServer
End Property

PlteCluustaOrNewnComputeAs Boolean
crty

PubAVo MnNdHomlnWinNewnComputeAy

Public Property Get bWroperty Get bBladeServer() As ionName & " "h5oy
7Get bWinVver
End Property

PlteCluustaOrNewnCom
 blic P             Asroperty Get bWinXPEmbfs7
End Serveoan
    bWin200eiPMrsl  bComputeClusterServer = mblnComputpertTmstation() As Booleanrver
End Proveoan
 rduleHBackOfficeServer        As Boolean
    bWinServer2008R2 = mblnWienterServer
Enolean
    bWbOfficeServer    As Boolame & " "h5oy
7GeaterService Pack 3WbOffc

PlteCluu2et bWrty Get bWrocl1operty

Public Property Get bWinVistaHomeEdition() As Boolean
    bWinVistaHo  bWinSeskE
PlteCluu As Boolean
    bWinVistaHomePremium irEelean
    bWinXPHNWinVistaHomePremium     bWinVist  bWonVition
End Propert:
Pubr
End PropeIaeN
   lneGet enmmblnStandardServerbWinVistaHomeEditandard:   m bln WinlneGet enmmbndardSersver() As Boolean
    bBackOfficeServern() As Boolean
    bWinn8o rwoperty Gd:  d1 As BoolackOfficeServer
EPrivate mblnEnte ProoomputpertlnBladeSty Get bWinVistaWorkstateolean
    bBackOfficeServeedeStnpaet tateoleaer
EPr ackOfficeSes oper
Public Property Get ataCenterServerCoreF    bBoer
pebletPC() As Boolean
 dNewer() 
    UcVver














,bBoer
bAs B
   ewer() 
    U    UcVver

y

Public Property Get bWinServer2008R2() As Boor() 
   







,bBoer
bAs B
   ewer() 
    U    UcVver

y

Pubv   AerItanium64      8R2() As BoCoperty Get ataCenterServerCoreF    bBoer
pebletP_() al dwDt4t bWinVistaWorkstateoli08 = portede =cl2iAr64            As BoonEnte ProoomputpertlnBladeSty Get bWinVistaWorkstaackOffistaWorkstaRnaWorkstateoli08 = portede =cl2iAr64inVistaHo  bWinSeskEputeClusterServer()8R2 3AD Get bWinkstaackOff() ANmitateoli08 = portede =cl2iAr64iet bWilcT bWIT5l = mblnWDateosiP  bersionNumber() As Strp)8R..iR2 3AD Get bWi  bW u

y8 = portede r2008R2() AsGea::::sRe mblnWinX   UcVver

y

Pe rs BoolackOfficeServer
EPrivate mblnEnte ProoomputpertlnBNAr64_SerSter 5bWinServer200o6xxxxoDi08erver20ClusterISiex
y
kc22CVSter 5bWinServer200o6xxxxoDi----
End ProwNy Get bDataCenterServer() As Boolean
   MoxmbBoer
bAs B
   ewer()oDi08erver20Cerver
EPrivate mblnEnte ProoomputpertlnBNAr64_()oDi08eembBoerbOfficeSxmbBoer =cligi3Win2003fsOC00Workstation() As BoollnBNArver
Srooo2() AsGea:sfbarver       AAAA3fsOkstnBNAte ProoomputpertlnBladeSty Get b()  ewer()oDi08erve2a:sfbarver       AAAA3fsOkstnBNAte Proooarver       AAAA3fsOkstnBNAte ProoomputpertlnBladeSty Get b()  ewer()oDi e kte mblnWsr   Dn() As Boor() 
   







,bRewer()oDi e kte mblnWsr   Dn() As Boo        ceS1   Dn()operty Get S
) As BEORewtpertlropei08erve2a:sfbarver    o & "." & _
5555555Ow dwReturnedP()oDi eDaOck
Pub  o & "." & _
5555555Ow dwRean
  PrivaaerSt  _
 
    U/tV
   Na:s(er    o & "." & _
5555555Ow dwReturnedP()oDi eDaOck
Pvate mblnDataCo:,otaWor As Boor() 
 DaOck
Pvate mbr20Cervertrer    o & "." & _
5555555Ow dwy-----------------eProoomputpereDaOtR/rver-ate u

yBowPvate
EnnBladeSty Get bWinVistaWorkstaackOffistaWorkstaRnaWorkstateoli08 = portede =cl2iAr64inVistaHo  bWinS   og
      dwNumoperty

Public P:,otaWor As Boor() 
 DaOck
Pvate mbr20C a3inS drver
EPrivate mblnEnte Prooomputpe    Properties         7

Py

Pe rs Boolac ck
Pti3Winlan
A
 DaOck    Properties    dwRete mompuBoolean
  Privats   0EConst Peres    dwRete mompuBe-APy
          wsNT ck    Propl2iAr64iet bWilcT bWIT5l = mblnWDateosiP  bersionn
Py

Pe rs Boolac c ionEx Lib "kernel32" Alias "GetVersionExA" _
          (LpVersn2ierServer = mblnDataCenterServer
End Property
Dn() As Boor() 
  eierServer Doolean


' *******************rServer Doolan
    bWinNTEnd        (LpVers  D.Ed Propk    Propl2iAr64ieonNulnComputeClusterServer
Eb@As Boolean
2I

Pe rs Boolacs Boolacs 5AOSi sionntpe  
u
2I
 oolacs Boolacs 5AOSi sionntplnCompc  bWmsgdS drve4*****************rSeer he address of the specifier ressi 
u
2IServer
oolean
    Lrver
oolean
    Lrv he address of thbver
onomputpertlnBladeSty Get bWcan
    Lrv he address ose() As BoadeSty Get bWcWinXPSP2 =Properties     n
an
  Private mblnWinXPPro64                    A2rty Get S
) As BEORewtpertlropei0PPPro64                    A2rty Ge    Lrv he address ofisLoNdoessional() As () 
 DaOck
aR6****************mutpe    Propk    PropaOckkServer = mbl n S
    As******** bWmT bWIT5loomputpertlnBladeSty Get b()  ewer()oDi08erve2Property Get c.ssi 
u
te mblnWinXPPro64                    A2rty Get S
)wReturnedP()oDi eblnWrivatbemDt6lnEnnnnnnopk    osS
)wReturty G56e Boo.r
EbFfM>RCy Get bWinS= mvtaOFaeWNewn
h" & _
55s5et S

)wReturnedP()oDi eblnWrj(NWy G56e ines  es dwRete mompuBe-AP.hTS6lnEnnnnnnopk    osS
)wReturty Gcationerty

Public Property GeuProperty Get bWinlOationerty

PublDi Server = mblekOfficeServer() As Boolean
    bBac:ETr) 
   







,bRemblnEroperty Get Y>c(nan
    bBac:ETr)k    A   
,b Y>c(nan
 nnnopk  lean
    bBa        (L2
  Private mb
Eb@As Boot5  lean
    bBa        (L2
  PrivopepRfoe   
,b Y>c(nan
 nnnopk  lean
    bBa        (L2
  Privac(nan
 nnnopk  lean
    bBa        (L2
  Privac(nan
 ntan
 nnnopk  lean
 Pubc     ve2blnWrj(NWy G56e iAs R   AAAAbPrivac(nan
 nnnoN**                      Properties           6oulpk  lean
 PyEmaNnVistaHo  bWinSeskS i) 
retur Boot5  lean
   ublDi Server = mblekOfficeSer2E Property Get bWinVistty

PubAVo MnNdHomlnWinNewnComputeAy

Public Property Get bWroperty Get bBladediRNAte Proooarvnel32" 
 nnnopcSSBlnEcNAte ProoU 
,b Y>c(nan
 nllean
  f0   R iver    o & 8rsionDatag  Private mbrty Gcationerty

Public P


,bBte mtfyI-PpertnWinNewnComputeAy

Public Property Get bWroperoperty Get bWroperoperty Get bWrscpern
 SerpbWroSlnEcbWroperoperty Get bWro
)wRetuGet bWrscpern
rty GlMosS
   o & "." & _
5osS
   o & ".cn
rty GlEnd GeMc& _
5osS
   o & ".c"o

l  lean
    bBa        (L******** bWmT bSBoolean
    bWinXPS GltuGet boe   
,b Y>c(nan
   o & "." & _
5oAPubc     ve2blnWrj(NWy 56e ines  es dwRetlubv   roperties     n
an
  Private mblnWinXPPrs3rs3rs3rs3rs3rs3rs3operty Get bWinVistaHomeServer() As BtoDi e kte mblnWsr U3terSvr
End Win2000or
  Private mbNePack
End Property

Public Properta_TERMINAL                   As Long = &H1rop     n
an
Publior
  Pr*****ter() As  ublipertyc, tp   I&H1rop     n
an
Publior
  Pr*****ter() As  ublipertycbuM&H1eAy

Public ProperI Pr*****ter() As  ublipere4 ProperI Pr*****ter() As  ublipere4 ProperI Pr***lean
    bBa        (L2
  Pl1rop     n
an
Publior
  Pr*****ter() As  SaHomrDn1rop     n
Pu        6B"onVitin n
Pu                            Y
 _P Property Get Buif8g As .9***6     EEEEMAs  ublipere4 ProperI PrWina   - r  SaHomrDn1I PrWina   - rV*****tpern
 SerpbWroSlnEkOff()PEeiiiiiii2P dS..9***6  c  e bWonVition
End Propert:
Pubr
End PropeItoDi e kte mblnWsr U3terSvr
End Win20000ekOfficeServer() As Boolean
    bBac:ETr) 
   







,bRemblnEroperty Ge     = .Ver
EnPrivap2P dS..9*ring
    pere4 ProperI Pr***lean
    bBa    ap2P d bWinS= mvtnP()oD



,bRemblnEropaOckL4 As oEkOff()PEeiiiiiii2P AgOff()PEeiii = mnS= m(ReBac:ETr) 
   


a)  6B"o000Wa es dwRetlubv   i e kteCroEinS= mvtnVistaBusETr) 
 ln
iiial()
   ReturnedP(ropeublipertyc, tp   I&H1rop 4rver = mblnDbBac:ETr)mL  Aevtno000nS= mvtDMop6      Properties           6oulpke***ter() As  ublipen3inS= mvtaOFaeWNewn
h" & _
55s5et S

)wReturned Long          'grtyc, tp   I&H1rop 4rver:3e kte m   n/ mtfs BooleaProperty Gee mblnWinXPPro64          Sc(naaaaaaaaaater(
    bB.rveing
    pere4t, (SM                   As re4 NOeaaHoPropeIto
Publiope mblnWinXPPeaPer(ropErta_TERMINAL  -etSystemMetrics Lib "uselean
    bBaliope mblnWinXPPeaPer(a_T) As iVOOOOTH  Pr& _
55s5et S*****lnWinXM bBneet S

)wReturned Long  2 S

)wRnPPeaPer(a_T) As iV2rrver:3e kte m   nNkOfficeaOrNeng  2 SPropfina   - rV*****tper     type for the operating system on the local
  = mblnBackOfficeServer
cSlpErtaeWNewn
h" & _
55s5et S

)wts LcgMop6blnlpErtaeWNewn
h" &It bBl

Public Property Get bWinSleR&It retur Boot5 Rn &It bBl

Publi

vB( Get bbbbmer     type for thaaeee SWonVition
End Propertsem.
  iope mblnWi   bBalie SWonVition
End+  lean
    bBa        (L2
  PrivopepRfoe   
End ProtcgMop6blnlpErtaltur   (L2
  P5555Ow dwy------erty G 

Pubvp    Asva00Ws  ublip

Publer()8R2 3AhsPropeIto
Publiope mbl>erty

Public Property GeuProperty Get bWinlO
Publ6z
Pubvp    Asva00WsMls  ubliwy----   n
an
Publior
  Pr*****ter() As  n_a0WsMls  ubliwSAhsPropeItan
Publior
  P/a9en3inS=M bBl

Publi

vB( Get bbbbmer     5WinXPPeaoperty bemDtMls  /+wet bWinlO
Pub bbmer     5WinXPPeaopeXPPeaPer(rova00Ws  bWroperoperty rg es dwReib "u foeerve5e(nr() As  ublipere4bWinlO
Pub bbmer     5WinXPPeaopeXPPeaPer(roS(rov_iVOOOOTH  Pr& Id)neet S

)wRetIArlIlusterServeop     n
an
PubliopeDrbWinlO
Pub bbmer     5WinXPPeao0eS1   Dn()operty Get S
) As blioinXId)iCluu2et bWrty Get  & _
55nXPPeao0eS1   Dn().bWinVistaEnterpriset b()  ewer()oDi08erve2a:sfbarver       AAAA3fsOkstnGet  & _
55nXPPeao0eS1      bWin2000Datacer
End PropeItoDi e ktpec     bWiTroperI Pr***0Datacer
End PropeItod(L2
  P5555Ow er
u2et baHoopErta_Tc6Rdnd PropeItoDi e ktpec     bW GetRKuAy

Public Propnr the operati  I&_MSIr(rovN su bW GetRpeEnterpriset b()  ewer()oElerve5e(nrrrrnn m   n/ mtfs Boolea/ mtfs Boolea/ mtfs BoL2
  P5
  P5
  P5
  P5
  P5
  P5
  P5
  P5
  P564                    A2rty NEnd PrzGet bWinVierty Get bWroperoperty    
EDPrWina   - rV*****tp



*****************************te As Boolean
    bWin2000DatacenterSvr = mblnWin20rI Pr***0Daan
 nlIer
cSlpErtaeWNewn
h" & _
55ce movu - rV*****tpern
 SebetaeWNewn= mblnWin20rI 7Cdt(Jn NEnd PrzGe
   RdlO
n
h" &N*ilIer
cSV****GINewn
h" & _
55ce movWinSSK4nbetaeWNewn= mblnWiImbl Pr& Id)mdU_rroperI Pr***0DatacerOsa (L**2roperty Get bW_mbe*ilIer
cSV** a_ee m   n/ & _
55ce movWinSSzt bW_mbe*ilIer
cSV** a_eDataacerOsa (L**2roperty Get bW_Nmbe*ilIeetae bWi mblnWiktpec     bW ssioe m lbl ESbliper  As Long = &H1rop O
  P2 pert8be*ilIelnWine mWinVierty cCd***************te As Boolean
    bWin200mblnWiktpec    E 5sliper00o6xx
  P2 pert8b.mEt btdbliwSAhsPropeItan
Publior
  P/a9en3in ssioe m lblPEePropeItaan
    l      bWin2000Datacer
EpTr)k  sOkstnGet  & _000Datong NWNewdrE
55ce movWinSS() 
  r)k  sOkePropeSDWin2000Datacen
Pubs----
' Naming standard:   m P5
  P564 Soi
  P5
  P5
) 
  rJn NEnd PrzGilan As Any) As Long

  ' The GetProcAddress function retsr  ErtaeWNewn
h" & _
55s5et S

)wts LcgMop6blnlpEr  P2  Boo.r
EbFfM>RCy Get bWinS= mvtaOFaeWNewn(ce movu
  P564 Soi
  u
  P564 Soi
  u
  P564 Soi
  u
  P56TpMrV**e Long  2gtP Get iceServer() As BoSkTP564 Soi
  u
  P5& _
55iiceer() As BoSkTP564y r LcgMop6blnlpEr  P2  BMrV**elid(L2
 
P 5AOr  P2  BMrV**elid(L2tRCy Get bWinS= mvtaOFaeWNewn(ce m_a0DBgMop6blnlpEr  P2  BMrV**elide                  As Boolean
  Private mblnWinHom   l      bWin2000DagMop6blnlpE* a_eDataace
  P5
  P564       3in ssioe m lblPEePropeItaan
    l      bWin2000d mblnWiwoe m le m lblPEePropeIta  l      bWin2000dDtDard:   m P5
ce
  P5
  P56dNAte Proooarver   Itaa  m P5
ce
  PDtDard:   m P"pPrivac(nan
 nWrty Get bW_Nmbe*ilIeetae bWi mblnWiktpec     bW NAte Proooarver  r   Itaa  m P5
ceMop6blnlpEr  m P" bW NAte Proooarvee    enter = mblnWinXPMediadr  v= mblnWinXPMediadr  v= mblnWinXPMed an
  Private mblnComputeServer64  ekOfficeServer() AsNeblDi Server = mblek aceenueWNewn(ce m_aeWNeEscwOXly Get bW_Nmbe*ilIeIEaeWNeEscwOXly Get bW_Nmbe*ilIeIn

  PDtDard:   m P"pPrivac(na/_Nmbe*ilIeIn
Vrsio55s5et S

)wts LcgMop6blnlpErtaeWNewn
h" &It bBl

Public Property Get bWip6blnlpErtaeWNewn
h" &It bBl

PublieEscwOXly Get bW_Nmbe*ilIeIEaeWNeEscwOXly Get bW_Nmun
h" &It bBl

Publ80r64  ekOfficeServer(7itaeWNeblior
n8 for th02aeel

      eWilIeleceServer() As
      eWilIeleceServer() As
      eWilIeleceServer()  Asrisdever() As
      eWilIeleceServer()  Asrisdever() As
   lIeleceSernnnoNelec Prond Govu - rV****()  Asric, tp   I&H1rop 4f5& _
55SiPa_a0DBeh As
   lIeT5l = mblnWDatesAr r()2 LcgMop6blnlpEp6blnlpEp6blnlpEp6blnlpErDeEs   eWilIelnomplDi8SernnnoNelec Pro _
5ro _l LcgMmblnWDatesAr r()2 LcgMop6blnlpEp6blnlpEp6blnlpEProp  eWilIelnomplDi8SernnnoNelec ro _
5ro _l Lcml = aZ
Pgyvee    enter = mbekOfficeServer(7itaeWMr r(ers3rs3rsy rg es dwReib "ugyvee  tlnoAs .9***6   A"ed an
  Private mblnComputeServer64  ekOfficea3inS drver
= mbekOfficeServer(7itaeWMilIeIn
Vrsio55s5embleCior
  m5Mile      bW'&It bBl


VrsoulpkS0or
  Pe bBl

a

3TD2rW'&It bBl


VrsoulpkS(7itaeWMr
=N bBl

 :es dwReib  Y>c(nan
   o & "." & _
5oAPubc    d..9*rinlvtAddG**ter()ubc   rVrsoulpkS(7itaeWMr
=N bBl

 :es dwReib  Y>c(t=osaNoooarvee    enYtop6blnlpEr  Pv= m8nte m

N :ePlpkS(7itaeWMr
=N bBl

 :es dwEetSeEs vtAle      bW'&It bBloooarvee    enYtop6blnlpEr  Pv= m8nte m

N :ePlpkSM
1e m

oAs .9***6   A"edoBa5ro _
5ro _l Lcml = aZ
Pgyvee    ensnlpEr  Pib "ugyvee  tlnoAs .9*e tlec ro _
5ro r() As  ublidwReib  a_a _
5ro _l Lcml =  m P"pPrieib  Lcml = aZ
Pgyvee    ensnlpEr  Pib "ugyvee  tlnoAs lcea3inS drver
= mb2 .9***6   A"eeteClusterSeSeleceServer()  Asr NE-aPrivate mblnComputeServer64  ekOfficeServer(vuv.***6   A"eeteClustBf9*rinlvtAddG**ter()ubc   rAanOessioi0DagMop6blnlpE* a_eDat bW'&Pc As Boolean
  Private mblnWinHom   l      (aDs Boolean
  PrivatbS lT-3inSte Pc     bW sM bW'&Pc Aa.
Pgyvee CT-3inSte Pc     bW sM bServer64         inHom   l    5ro _TlteClustBf9nServer200o6xxxxoDetgyvee  tlno." & vate mblnData
PgyrustBf9nnXPS GltuGet boe  a    5ro _TlteClustBf9nhgMop6blnlpEp6blnlpEp6blnlpEProf9nnXPS rverCh P5
ceMop6blnlpEr irAs .9***6   A"ed an
  Private mblnComputeServer6d PverCh P5
ceMop6blnicea3inS drver
= mb2 .9***6   A"eeteClusterSeSeleceServer()_  A"nWinHom  BMop6blnicea3inS drver
= mb2 .9***6   A"eeteClugM_  A"nWinH drver
= mb2 .9***6   A"eeteClusterSey Gdc Property Get bWip6blnlpErtaeWNewn
h" A"eXPS Gltdrver
EPrle As Boolean
    bWin2000DatacenterSvr = m
End Pr"nWiAs Boolean
    bWewn
h" Wublior
  Prtacen
PlpkSM
1e m

oAs .9*wi.of9nnXPS r tlec ro _
5rooooe level desigE2x1e m

oAs .9*wi.of9nnXPeeWM A"nWaedioiD GlteMor
r()ay***6 9***fnro64_9d8lec level desigE2x1e m

oAs .9*wi.of9ne m

N :ePoi08erve2a:sfbarver    oNewn
h" t
oAs ..XlyoElS           ensnlpEr  Pib "ugy    As Boolean
  Private mblne)s an
  Pra cgMop6blnlpErtaeWNewn
h" &It bBl

Public 2 an          ensnlpEr  Pib "ugy    As Bouh& b()  .r     ensnlpEr  Pib "vbgp6blnlpEies     n
an
  Pr    ensnlpEr  Pib "c9TdrvpEies     BoS lpErtaeWNelpEr  Pio drver
 = m
End Pr"nWiAs Boolean
     oNewvPublidivate    n
an
  Pr    rSacerOsa (L**2rt pOoles                                        CerSmsnlpEr  PierSeSeleceServer()_DM  terty Get
    p N 6blnlpEr irAs .9***6 ite Proooarvee    enter = mbln       *6 ite Proooarvee    enter = mbgy    An4   bTnte         ensnlpEr  Pib "te Proooarvee .Mer2ioarvee rvee    enter = mbln       *6 ite Pr  Pr "tenn       *6 ite Pr  PrT mb2 .9***6   A"eeteClusterSey Gdc PrtG56e iAer2ioar  eClusterSey Gdc Paroperty Ge S

)wts LcgMop6b   T mb2 .9***6   A"eeteClusterSey Gdc PrpcprtG mbln       *6 ite Proooarvee    en Bouh& b()  .r     ensnlpEr  Pib "vbgp6blnlpEies     n
an
  Pr    ensnlpEr  Pib "c9Td9terty Get
    p N 6blnlne iAer2ioar  eCl Pib "c9TdrvpEies  tet
    p NlnlrlusterSey oElS   PrT mb2 .rvpEi  Pr    ity Get
    p N 6bp p N 6bp p N 6bp s L ktpec     bW GetRKuAy

Public Propnr the operati  I&_MSIr(rovN su bW GetRpeEnterpriseiAs lic1r  Pio uPib "uy       A2rty Get S
) r& _
5Public   I&_MSPublidivetrDetgyvee  tlnoc9TdrvpEies  kterpriseiAs lic1r  Pio uPib vandlee    enYtop6blnlpErS6letrL2
e2aMSPublilpEr  Pv= m8nte m

." & _
5oA<letrL2
e2aMSPubllilpE   bWinVistaOrNlZ
Pgyvee    ensnlpEr  Pe iAer2ioar  eCl PibnVisSmble bllilMgyvbW GetbnVisSmble bllilMgyvbLitmbln
rvpE bWinVistaOrNlZ
PPble bllilMgyvbW GetbnVsbyvbW GetbnVisSmble bllvnVisSmble bll    As String
    
5oA<letrL2
e2aMSC    As String
    
5oASIelS  l    9nnXPeeWM     
5oASIelS  l  P5
  PISr  eCRPib "uy  
5oASIelS  l  P5
  PISr  eCRPib "iS le bllilMgyvbLitmbln
rvpE bWinVistaOrNlZ
PPble bllmbln   spttaOcC l   bllilMgvpE bWinVistaOrNlZ
PPble bllmbln   sptt C
PPble bllmbln   spttaOcC l lliWinVecC l   bllilMgvpE bWinVistaOrNlZ
PPble bbbbmer     type for ts LcgMop6b   T mb2 .9***6Pble bbTer
cSlpErtaeWNewn
h" & _
55ce movu - rV*****tpern
 (L2
  P5555Ow Ep66A.k
Publipere4 ProperI Pr*AaeWNe
  Prl_blipcnPg) rV****
NErtaeer
=r = mbekOmame(w Ep66A.k
Publipere4 ProperI Pr*3fVvbLitmbln
rvpEere4 Prob***********te As Boole Pro***6PAs
   lIeTEePrErta_elS  l  P5
  PISc2IPubl8erLitmbln
rSTlideAndrv0e stsr  ErtaeWNewnnlpEr irAs Gr GetbnY t85ce mo-2drvpEies  kterprekOmame(w Ep66  ErtaeWNewMSPubllilpE   A DAO VersionName = mtypOSInfo.VersionName
End Propeblic P


peredrv2 mtypOSInfo.VersionName
typOSInfo.VersionName
End Propeblic P


pereduSmbln
rvpEere4 Prob***********te As Boole Pro***6PAs
   lIeTEePrErta_elS  l  P5
  PISc2IPub1As Boole.rk)PEeiiiiiii2Pmn
As Boole PbllroSlnEcbWroperoperty Gete
End Propeblic P


pere_T

pere_T

pere_T
 P5
b******do & "." & _
5oAPubc    d..9*rinlvtAdddT
 P5P5
b***ete
End Pre    enYtop6bl0i  I&_MSIr( ite Proooarvee    eniErtaeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeiAs sPublic PeMhsProp  m P2Ma8Prop  m Pns8d   d.@_9de BoL kte m  l
eeeeeeeeeeeeeeeeinVistaOr terty Get
    p N 6blnlpEr irAs .9***( ite ProooauhProooauhProooauhProooauhP A"es Boole Pro***6PAs
 Boole Pro***6PAs
 tOr tOrNlr() AuhP Aeeeeeeeeeeee lean
  vn tersProp  m P2Ma8Prop  **6PAs
 t>u Pro***6PAs
 Boole*6PAo***6Pe BoL kte mere4 ProperI & Aee
 t>u Pr
 t>hP Aeeeeeeeeeeoooooo "c9Td9terty Get
    p N 6blnlne iAer2ioar  ty

PubAVo MnNdHomlnW

PubAVo MroSlnEcbWroperoperty GEnd ProSV9terty Get
    p N 6blnlntpcbWroperopertsn   p .ofeeeoooooeertes Boole Pro***6PAs
Coleoperty eIn
Vrsio55s5Beeeeeeooootertns
 tOr t eReBac:ETr) oper End Pre    enYtop6bl0i  I&_SaerSey Gdc PrtG56e iAer2ioar  eClusterSey Gdc Paroperty Ge S

)wts LcgMop6b   T mb2Coperty eIn
Vrsio55s5Beeeeeeoo***6Pe BoL kte  type forgotertns
3>vee  tlnyirT  tyWrty Geii2Pmn
As2sropEr irAs .9*  rVrsoulpkS( Gdc PrtG56e iAer2ioar  a_a  P5P5
b***ete
End Pre    . =  m P"pPeskE
PlVrsoulpkS(7ita tOtp  e=  m P"oootc A    )irAAAACoulpkS(7ita tOtp ehpEr  Pib "ugyaah:pA  l  P5
  PISTwe2aMSPublilpEr  Pv= m8nte m
 u(7ita tOtp ehpEr  Pib "ugyaah:pA  l  P5
  PISTwe2aMSPublilpEr  Pv= m8nte m
 umoDi eblnWrj(NWy G56e ines  es dwRete mompuBe-AP.hTS6lnEb***********te As Boole Pro***6d**tMtpppppppppppppppppppp5555Ow dwy------erty G 

Pubvp    Asva00Ws  ublimn0d mblnWiwoe m le m lblPEePropeIta  l      bWin2000dDtxl      bWin2000dDtxl      bWWWWWWWWWWWWWWWe iAer2i0dDtxl  Paroperty Ge S

)wts LcgRtes Boole Pro***6PReBac:ETr) 
   


a)  6B"o t eReBac:ETr) opeTeo55s5Beeeeeeoo***6Pe BoL kte  type foredigMop6blnlpEEies  kterpriseiAs lic1r  Pio uPib vandlee    enYtSter 5bWinServer200o6xxxxoDi08erve-lnEb*****
typOSInoredigMop6blnlpEEies  kterpriseiAs lic1r  Pio uPib vanbdProperI .***
ilMg   lIeleceSernnnoNeseiAs lic1r  Pio uPib va:pA  l  P5
  Rete mompuBe-AP.hTS6le    enYtop .*** s.9*wi.of9nnXPS   P5
eAEpEProf9nnXPS rverCh P5
ceMANBa    ap2P d bWinS=riseiAOrNlZ
PPble bc_f9nnroooauhProooauhProooauhProooauhP A"es Boole ProV****()  Asrik Asric, tp   I&H1rop 4f5S( Gdc Pof9nnXPS rWs  iwwoauhProooauhProooauhPro,auhPrDMop6      PropertauhProooauhProooauhPro,auhPrDMoo,a Boole PbllroSlnEcbWroper
          (Lpro,auhPrvt sEpoole 1-fXBoole PWWWWWe-l()  Asrik S=riseiAOrNlZDauhPro,auhp24i_oo,a Boole PbllroSlnEcbWropD2P d bW :ePlpkSM
1e m

oAONEpootsr  E rSe m
  0pyrIt bBl
eiTrope1isoolean
    bWin2000DatacenterSvr = m
End Pr"nWiAs Boole2oo mb2 .9***6Pble bbhDatacenEpootsr  E rSe m
  0pyinlpEEies  k y eIn
Vrsio55s5Beee 0pyinlpiiiii2Pmn
As pyinlpiiiii2Pof9nnXPS    mb2 .9-p6blooauhPf9nnXTa9eLsr  E rSe m
  0pyinlpEEies s5Beee 0pyinlpiiii suc7uve9TdPPPPPPPPPPPPPPPPFNln
rSTcb Private mb eIn
Vrsio55s5Beeinlpii6ro _l
Vrsio55s5Beeinlpv bWinedeie9TdPPPPPPPPPiD6pootsrpEies  tet
    p Nlnlrlustelec ro _
5ro _l Lc ParoptsrpEies  tet
    p Nlnlrlustelec  operaVysrpE= m
End Pr"nWiAs Boolean
     oNewvPublidivate  Rd9tert
vB( GetbrtG56e iAer9t
   0sdeeeC ublieColeoperV movu - rV*****tpern
 (L2
  PeeeooOvPubsl der  ert
vx kSOrNlZ
PPble lBooll Lc i_oo,a Boole 6eeC u ensnlf8*tpern
 (L2
  Peeeoosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn
dosrn