-1

when user installed my application I want to get the users android OS(version, Name) to validate .I tried with different examples but cant find the solutions and wasted my time.

Deepak
  • 192
  • 1
  • 2
  • 18

1 Answers1

2

You can use:

      android.os.Build.VERSION

It provides info about:

  1. CODENAME: The current development codename, or the string "REL" if this is a release build.

  2. INCREMENTAL: The internal value used by the underlying source control to represent this build.

  3. RELEASE: The user-visible version string.

  4. SDK_INT: The user-visible SDK version of the framework; its possible values are defined in Build.VERSION_CODES.

For more info: LINK

Umer Farooq
  • 7,356
  • 7
  • 42
  • 67