Windows' versioning structure has changed many times over the years. Over that time registry values have come and gone, and some still remain but contain old data. I would like a source that tells me how to build a detailed version string for each version of Windows.
I have found many non-offical sources but all of them are incomplete. I would like a source from Microsoft or a source approved by Microsoft.
https://ss64.com/nt/ver.html is the best I've found so far but it doesn't go into UBR or CSD
ver? It uniquely identifies the Windows version, even if you may have to look at a table. // Not sure what you might be referring to by “UBR” or “CSD”. – Daniel B Oct 06 '22 at 18:50veris quite stellar, but a non -CLI technique would be more ideal (e.g. a win32 API, or a guideline for where the version information has shuffled to/from over the years).In my experience, ss64 is often THE authoritative location for these things, and for that reason, I donate to his charitable website annually to help keep it around. – tresf Oct 06 '22 at 19:24GetVersionExget you what you need (https://learn.microsoft.com/en-us/windows/win32/api/sysinfoapi/nf-sysinfoapi-getversionexw)? – heavyd Oct 06 '22 at 19:47ver. – tresf Oct 07 '22 at 04:10any logic using it will break with the next version of windows-- This is speculative. It may break. Note that Windows has deprecated many APIs over the years that still work decades later, such as GDI. – tresf Oct 07 '22 at 04:12ver. It's the only thing you can blindly trust to work in the future, since the OS rather irrationally reports10as the major version forWindows 11and the minor versions for e.g.Windows 12,Windows 13haven't yet been published. Of course, this isn't to minimize the security risk of an OS blindly allowing an application to run console commands to begin with -- something sandboxed apps on certain platforms can't do -- but it's at least a detectable, known-working fallback that's most likely to keep working. – tresf Oct 07 '22 at 06:28Windows11OrGreaterand increment... which despite being missing from the official docs still manages to be showing up in projects, some projects claiming it will eventually be added. – tresf Oct 07 '22 at 06:39