This is a myth. The Win32 API doesn’t even have a method that returns the string “Windows 95”! Windows version numbers are numbers, not strings. Windows 95 was actually 4.0. Windows 98 was 4.1, ME was 4.5, and XP was 5.0.
Actually it’s not entirely a myth - there was some Java library that did this - but it wasn’t widespread at all, and certainly not the documented approach to check the version.
Close but not exactly. Windows 5 was 2000, Windows 5.1 was Windows XP.
But it’s more confusing than that because of the two different lines: the MS-DOS based line which covered Windows 1.0 through ME, and the multi-user NT line for workstations and servers which adopted the same version numbers as the currently released MS-DOS line that was available at the same time. I.E. windows NT 3.1 used the windows 3.1 UI from the DOS line, but was New-Technology instead of DOS under the hood. NT4 used the DOS based win95 UI, and NT5 was Windows 2000 also with the familiar Windows 9x UI. Everything since XP has been exclusively NT under the hood.
The reason there isn’t a Windows 9 is because there was a common test for windows versions that went something like this:
std::string winVer = getWinVerStr(); if (winVer.find(“Windows 9”) != -1) { // This is windows 95 or 98 }
A good chunk of older programs would likely have issues.
This is a myth. The Win32 API doesn’t even have a method that returns the string “Windows 95”! Windows version numbers are numbers, not strings. Windows 95 was actually 4.0. Windows 98 was 4.1, ME was 4.5, and XP was 5.0.
Actually it’s not entirely a myth - there was some Java library that did this - but it wasn’t widespread at all, and certainly not the documented approach to check the version.
WMI was introduced in XP (I think? Was it later?) and asking WMI for the version string was pretty common.
Close but not exactly. Windows 5 was 2000, Windows 5.1 was Windows XP.
But it’s more confusing than that because of the two different lines: the MS-DOS based line which covered Windows 1.0 through ME, and the multi-user NT line for workstations and servers which adopted the same version numbers as the currently released MS-DOS line that was available at the same time. I.E. windows NT 3.1 used the windows 3.1 UI from the DOS line, but was New-Technology instead of DOS under the hood. NT4 used the DOS based win95 UI, and NT5 was Windows 2000 also with the familiar Windows 9x UI. Everything since XP has been exclusively NT under the hood.
Thanks for the correction :)