static bool isWindows10()
{
string currentVersionKey = "HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion";
int majorVersion = (int)Microsoft.Win32.Registry.GetValue(currentVersionKey, "CurrentMajorVersionNumber", 0);
return majorVersion == 10;
}