/// <summary>
        /// Checks if Windows is higher or equal than a minimum version.
        /// </summary>
        /// <param name="minimum">The lowest possible version.</param>
        /// <returns>Result of operation system check.</returns>
        public bool VersionCheck(VER_PLATFORM minimum)
        {
            OSVERSIONINFO tVer = new OSVERSIONINFO();

            tVer.dwVersionInfoSize = Marshal.SizeOf(tVer);
            GetVersionEx(ref tVer);
            return(((VER_PLATFORM)tVer.dwPlatformId & minimum) == minimum);
        }
 public static extern bool GetVersionEx(ref OSVERSIONINFO osvi);