C#判断操作系统类型总结

本文列举了从Windows 95到Windows 8等多个Windows操作系统的版本号详情,包括PlatformID、主版本号及副版本号等信息,并介绍了如何通过C#获取这些系统信息。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Windows操作系统的版本号一览

 

操作系统PlatformID主版本号副版本号
Windows95140
Windows981410
WindowsMe1490
WindowsNT3.5230
WindowsNT4.0240
Windows2000250
WindowsXP251
Windows2003252
WindowsVista260
Windows7261
Windows8   

 

获取操作系统信息的相关类或属性
//获取系统信息
System.OperatingSystem osInfo = System.Environment.OSVersion;

//获取操作系统ID
System.PlatformID platformID = osInfo.Platform;

//获取主版本号
int versionMajor = osInfo.Version.Major;

//获取副版本号
int versionMinor = osInfo.Version.Minor;
System.PlatformID枚举值及其含义
Win32S 操作系统为 Win32s(Win32 子集)类型。
Win32s 是运行于 Windows 16 位版本上的层,它提供对 32 位应用程序的访问。
Win32Windows 操作系统为 Windows 95 或较新的版本。
Win32NT 操作系统为 Windows NT 或较新的版本。
WinCE 操作系统为 Windows CE。
Unix 操作系统为 Unix。
Xbox 开发平台为 Xbox 360。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值