none
Get Win10 Version & Build RRS feed

  • Question

  • Howdy,

    I already included all OS tags as well as Win10:

          <!-- Windows 10 -->
          <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>

    In app.manifest

    For example I'm running Windows 10 Pro/Ent, version 1511, build 10586.29.

    How can I simply in VB.NET (Target is .NET FW 4) get the above version "1511" & build number "10586.29"?!

    Just need to get 2 numbers "1511" & 10586.29". pure .NET method.

    Thanks in advance :)

    • Edited by OSVBNET Thursday, October 13, 2016 7:35 PM
    • Moved by Oscar_Wu Friday, October 14, 2016 7:13 AM related to VB
    Thursday, October 13, 2016 7:20 PM

Answers

  • Thanks a lot Me. Monkeyboy.

    This is a good and safe way to go.

    I can get the version release ID from ReleaseId, which is 1511 in my case.

    And build version number from either of these 2 keys: CurrentBuild & CurrentBuildNumber.

    Strange, both CurrentBuild & CurrentBuildNumber has the same values on my PC which is 10586.

    So which one should I use to be on a safer side and get the more accurate info on all systems.

    There must be some different between these 2 keys. But can't find what difference.

    Cheers.

    I have no idea and searching about those two keys people provide guesses why they are always the same.

    Also I found this link Where can I find the Windows 10 version and build number? where the author uses a command prompt I suppose with "systeminfo" and if you view the results they are different than what the upper image "About Windows" shows. The upper image says "Version 10.0 (Build 10240)" while the lower command prompt image shows "10.0.10041 N/A Build 10041" although the command prompt image in the upper images right shows the correct info.

    Regardless you can always compare against the BuildLab or BuildLabEx values I suppose as both seem to contain the OS build number. Or find an MS Forum that you can get an answer concerning registry questions in which I don't know one to ask in.

    If a post answered your question then please propose it as the answer.

    Update: Perhaps you could ask the question somewhere here Microsoft Community or at the right side of the link get help with the "Ask our virtual agent".


    La vida loca

    • Edited by Mr. Monkeyboy Saturday, October 15, 2016 6:04 PM
    • Marked as answer by OSVBNET Saturday, October 15, 2016 9:18 PM
    Saturday, October 15, 2016 5:52 PM

All replies

  • Hi OSVBNET,

    This forum is discussing Visual Studio WPF/SL Designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System, and Visual Studio Editor.

    Your issue may be related to VB development I will move this thread to corresponding forum for a professional answer.

    Sincerely,

    Oscar



    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place. Click HERE to participate the survey.

    Friday, October 14, 2016 7:13 AM
  • Hi OSVBNET,

    Gets an OperatingSystem object that contains the current platform identifier and version number. The following code example uses the OperatingSystem object to display information about runtime operating system.

    Sub Main() 
            Console.WriteLine("Operating System Detaiils")
            Dim os As OperatingSystem = Environment.OSVersion
            Console.WriteLine("OS Version: " + os.Version.ToString())
            Console.WriteLine("OS Platoform: " + os.Platform.ToString())
            Console.WriteLine("OS SP: " + os.ServicePack.ToString())
            Console.WriteLine("OS Version String: " + os.VersionString.ToString())
            Console.ReadLine()
    End Sub

    I also find a same issue about getting the version of the Windows from vb.net. Hope it helps.

    Best Regards,

    Neda Zhang


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Proposed as answer by Cor Ligthert Friday, October 14, 2016 9:36 AM
    • Unproposed as answer by Cor Ligthert Friday, October 14, 2016 6:06 PM
    Friday, October 14, 2016 9:30 AM
    Moderator
  • Thanks all,

    Neda, it seems to be the simplest thing to get OS info in .Net, but it's not!

    I still didn't found a simple way to get the above 2 version numbers!

    If you run your code you'll find that none of my requested information is returned!

    Windows 10, version 1511, build 10586.29 for example

    I just need to get 1511 & 10586 which for each build is different!

    Friday, October 14, 2016 1:04 PM
  • What happens if you manually use regedt32 to check this registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\BuildLabEx" for values? Does it provide the correct information? If so then use appropriate code to get the value from the key that you desire.


    La vida loca

    Friday, October 14, 2016 4:10 PM
  • Thanks a lot Me. Monkeyboy.

    This is a good and safe way to go.

    I can get the version release ID from ReleaseId, which is 1511 in my case.

    And build version number from either of these 2 keys: CurrentBuild & CurrentBuildNumber.

    Strange, both CurrentBuild & CurrentBuildNumber has the same values on my PC which is 10586.

    So which one should I use to be on a safer side and get the more accurate info on all systems.

    There must be some different between these 2 keys. But can't find what difference.

    Cheers.

    Saturday, October 15, 2016 3:36 PM
  • Thanks a lot Me. Monkeyboy.

    This is a good and safe way to go.

    I can get the version release ID from ReleaseId, which is 1511 in my case.

    And build version number from either of these 2 keys: CurrentBuild & CurrentBuildNumber.

    Strange, both CurrentBuild & CurrentBuildNumber has the same values on my PC which is 10586.

    So which one should I use to be on a safer side and get the more accurate info on all systems.

    There must be some different between these 2 keys. But can't find what difference.

    Cheers.

    I have no idea and searching about those two keys people provide guesses why they are always the same.

    Also I found this link Where can I find the Windows 10 version and build number? where the author uses a command prompt I suppose with "systeminfo" and if you view the results they are different than what the upper image "About Windows" shows. The upper image says "Version 10.0 (Build 10240)" while the lower command prompt image shows "10.0.10041 N/A Build 10041" although the command prompt image in the upper images right shows the correct info.

    Regardless you can always compare against the BuildLab or BuildLabEx values I suppose as both seem to contain the OS build number. Or find an MS Forum that you can get an answer concerning registry questions in which I don't know one to ask in.

    If a post answered your question then please propose it as the answer.

    Update: Perhaps you could ask the question somewhere here Microsoft Community or at the right side of the link get help with the "Ask our virtual agent".


    La vida loca

    • Edited by Mr. Monkeyboy Saturday, October 15, 2016 6:04 PM
    • Marked as answer by OSVBNET Saturday, October 15, 2016 9:18 PM
    Saturday, October 15, 2016 5:52 PM