locked
how to get os version on window phone? RRS feed

  • Question

  • how to get os version(8.0 or 8.1) on window phone?

    Friday, August 29, 2014 1:48 AM

Answers

  • Why do you need to know? What scenario are you trying to achieve?

    From a Silverlight app you can use System.Environment to get:

    • .Net framework version: System.Environment.Version
    • OS version: System.Environment.OSVersion

    Windows Phone Runtime apps cannot directly determine the OS version, but currently they run only on Windows Phone 8.1.

    Friday, August 29, 2014 2:19 AM

All replies

  • Why do you need to know? What scenario are you trying to achieve?

    From a Silverlight app you can use System.Environment to get:

    • .Net framework version: System.Environment.Version
    • OS version: System.Environment.OSVersion

    Windows Phone Runtime apps cannot directly determine the OS version, but currently they run only on Windows Phone 8.1.

    Friday, August 29, 2014 2:19 AM
  • The problem is WP8.1 has many versions. Sometimes it is very helpful to know the exact version because some versions have limitations or bugs.

    Hong

    Monday, April 20, 2015 9:28 PM
  • There are likely more direct ways to handle such detection than inferring it from OS version #, and much less risky. It of course depends on what exact bug you are trying to detect.
    Tuesday, April 21, 2015 5:33 PM
  • For example, to deal with this bug, we would like to tell the user something like this: "This app requires Window Phone OS  8.10.14176.243 or newer, unfortunately the OS version of your phone is: 8.10.?????.???.".

    Hong

    Tuesday, April 21, 2015 9:35 PM
  • What about running this app in the future? Hardcoding 8.1 onto an app that may in the future run on a 8.x or 10 device would not be accurate, so being able to pull / check this dynamically would be useful.

    Sadly the OSVersion and Version properties documented with the System.Environment (https://msdn.microsoft.com/en-us/library/windows/apps/system.environment(v=vs.105).aspx) are not actually available, at least not in my version of Visual Studio.
    Tuesday, June 23, 2015 5:05 PM