Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
Robert Hirtle250 Points
I cannot bypass this err. Error:(3, 22) compileSdkVersion android-22 requires compiling with JDK 7
I attempted to download JDK 7 and install but it still will not work. This prevents my preview screen from functioning.
Andrei Fecioru15,059 Points
You probably have Java6 installed by default but you need Java7 to compile your project. To verify this run the following at the command prompt:
$ java -version
If you see something like the following:
java version "1.6.0_65" Java(TM) SE Runtime Environment (build 1.6.0_65-b14-466.1-11M4716) Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-466.1, mixed mode)
then it mens that you have Java6 installed. Just go to the Java download page and download and install Java JDK7 or newer.
After installation please check that the correct Java version is being activated by running the same command at the command prompt.
Hope this helps.