Created
December 28, 2013 23:04
-
-
Save fethica/8165352 to your computer and use it in GitHub Desktop.
Retrieving Android API version programmatically.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int currentapiVersion = android.os.Build.VERSION.SDK_INT; | |
| if (currentapiVersion >= android.os.Build.VERSION_CODES.FROYO){ | |
| // Do something for froyo and above versions | |
| } else{ | |
| // do something for phones running an SDK before froyo | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment