   Dim lMajor As Long
   Dim lMinor As Long
   GetWindowsVersion lMajor, lMinor
   If (lMajor &gt; 5) Then
      m_bIsXp = True
   ElseIf (lMajor = 5) And (lMinor &gt;= 1) Then
      m_bIsXp = True
   End If
   m_bInit = True
End Sub

''' &lt;summary&gt;
''' Returns current running Windows Version.
''' &lt;/summary&gt;
''' &lt;param name="lMajor"&gt;Variable to set to the major version of
''' Windows.&lt;/param&gt;
''' &lt;param name="lMinor"&gt;Variable to set to the minor version of
''' Windows.&lt;/param