Comment get the ACTUAL version number for Windows 10 from commande line? (NOT build number!)
Comment get the ACTUAL version number for Windows 10 from commande line? (NOT build number!)
Comment get the version number for Windows 10 [`1903`], instead of the build number [`10.0.18362.592`], via ligne de commande?
Re: Comment get the ACTUAL version number for Windows 10 from commande line? (NOT build number!)
>
Comment get the version, such as `1903`, instead of the "build number"?
The following PowerShell command will provide the information you are seeking:
(Source: [Comment get Windows version from the invite de commandes or PowerShell](https://stackoverflow.com/questions/42778858/how-to-get-windows-version-from-command-prompt-or-from-powershell))
-
`(Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').ReleaseId
```
- Registry query from the command prompt:
`Reg Query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" | findstr ReleaseId
```
>
J'ai no words for this. I've been spending a ridiculous amount of time searching and searching and searching a million times, and every single webpage on the Internet keeps telling me about the worthless `ver` command or `wmic blabla`, which does not give you the version number.
I must point out the version of Windows you are using is actually the Build version (i.e. `18363`), instead of ReleaseID (i.e. `1909`)[.](https://superuser.com/questions/1330269/how-to-get-os-version-through-powershell-with-wmi)
- You would use `[System.Environment]::OSVersion.Version` to tell the difference between Windows 7 Service Pack 1 and Windows 7 RTM[.](https://superuser.com/questions/1693093/get-the-windows-10-code-name-e-g-21h2-via-cli-even-on-a-fresh-installation)
Comment get the version, such as `1903`, instead of the "build number"?
The following PowerShell command will provide the information you are seeking:
(Source: [Comment get Windows version from the invite de commandes or PowerShell](https://stackoverflow.com/questions/42778858/how-to-get-windows-version-from-command-prompt-or-from-powershell))
-
`(Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion').ReleaseId
```
- Registry query from the command prompt:
`Reg Query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" | findstr ReleaseId
```
>
J'ai no words for this. I've been spending a ridiculous amount of time searching and searching and searching a million times, and every single webpage on the Internet keeps telling me about the worthless `ver` command or `wmic blabla`, which does not give you the version number.
I must point out the version of Windows you are using is actually the Build version (i.e. `18363`), instead of ReleaseID (i.e. `1909`)[.](https://superuser.com/questions/1330269/how-to-get-os-version-through-powershell-with-wmi)
- You would use `[System.Environment]::OSVersion.Version` to tell the difference between Windows 7 Service Pack 1 and Windows 7 RTM[.](https://superuser.com/questions/1693093/get-the-windows-10-code-name-e-g-21h2-via-cli-even-on-a-fresh-installation)