参考链接:https://www.cnblogs.com/zengpeng/archive/2012/11/27/2790432.html
c#获取系统语言及版本信息
//当前操作系统是否为简体中文public static bool IsChineseSimple(){
return System.Threading.Thread.CurrentThread.CurrentCulture.Name == “zh-CN”;
}
//当前操作系统是否为繁体中文public static bool IsChineseTW()
{
return System.Threading.Thread.CurrentThread.CurrentCulture.Name == “Zh-TW”;
}
//当前操作系统是否为英语(美国)public static bool IsEnglish()
{
return System.Threading.Thread.CurrentThread.CurrentCulture.Name == “en-US”;
}
//当前操作系统是否为日语public static bool IsJapan()
{
return System.Threading.Thread.CurrentThread.CurrentCulture.Name == “ja-JP”;
}
———————————————————————————————————————
//C#判断操作系统是否为Windows98public static bool IsWindows98
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32Windows) && (Environment.OSVersion.Version.Minor == 10) && (Environment.OSVersion.Version.Revision.ToString() != “2222A”);
}
}
//C#判断操作系统是否为Windows98第二版public static bool IsWindows98Second
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32Windows) && (Environment.OSVersion.Version.Minor == 10) && (Environment.OSVersion.Version.Revision.ToString() == “2222A”);
}
}
//C#判断操作系统是否为Windows2000public static bool IsWindows2000
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32NT) && (Environment.OSVersion.Version.Major == 5) && (Environment.OSVersion.Version.Minor == 0);
}
}
//C#判断操作系统是否为WindowsXPpublic static bool IsWindowsXP {
get {
return (Environment.OSVersion.Platform == PlatformID.Win32NT) && (Environment.OSVersion.Version.Major == 5) && (Environment.OSVersion.Version.Minor == 1);
}
}
//C#判断操作系统是否为Windows2003public static bool IsWindows2003
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32NT) && (Environment.OSVersion.Version.Major == 5) && (Environment.OSVersion.Version.Minor == 2);
}
}
//C#判断操作系统是否为WindowsVistapublic static bool IsWindowsVista
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32NT) && (Environment.OSVersion.Version.Major == 6) && (Environment.OSVersion.Version.Minor == 0);
}
}
//C#判断操作系统是否为Windows7public static bool IsWindows7
{
get
{
return (Environment.OSVersion.Platform == PlatformID.Win32NT) && (Environment.OSVersion.Version.Major == 6) && (Environment.OSVersion.Version.Minor == 1);
}
}
//C#判断操作系统是否为Unixpublic static bool IsUnix
{
get
{
return Environment.OSVersion.Platform == PlatformID.Unix;
}
}
