In my android studio there is only the Marshmallow 6.0 API. Can i create the app also run on jellybean API without downloading the API of Jellybean? Thank you
Asked
Active
Viewed 455 times
1
-
beacuase you have not downloaded jelly bean 4.0 api. Open SDK manager and download. – karan Jul 13 '16 at 05:43
-
Thank you. Can I do that without downloading jelly bean API? – Vishnu N u Jul 13 '16 at 05:58
-
Yes you can. But if you want to run your application in Emulator which is running with Jelly Bean you should download the Jelly Bean API. – Shashanth Jul 13 '16 at 06:39
-
thank you for spending your valuable time – Vishnu N u Jul 14 '16 at 04:10
1 Answers
1
Yes, you can develop an app that runs also on an older version of Android. You should define "Min SDK version" for the module appropriately. If your code uses APIs that are not available on JellyBean, it's your responsibility to see that these APIs are not called. You can check Build.VERSION.SDK_INT
at runtime. It is nice to use TargetAPI annotations to avoid warnings about such code.