How to set JDK in Eclipse?

0 votes
I have JDK installed for Java 6 as well as for Java 7.

I am trying to build my project using both. How are these options added to the IDE? How would I get this to appear in the list? I have added two different JREs in my IDE preferences, but these are not what appears in the dropdown list.

How can we add JDK for both the versions on Eclipse?
Jan 3 in Java by Sushmita
• 6,820 points
31 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes
To manage the list of compilers go to Window -> Preferences -> Java -> Installed JRE's tab

Go to project build path configuration -> libraries tab, you can delete the entry for "JRE System Library", click on "Add Library" and choose the installed JRE to compile with. Some compilers can be configured to compile at a back-level compiler version.
answered Jan 3 by Daisy
• 8,020 points

Related Questions In Java

0 votes
1 answer

How to set Encoding in Java ?

Unfortunately, the file.encoding property has to be specified as ...READ MORE

answered May 29, 2018 in Java by Rishabh
• 3,520 points
2,874 views
0 votes
1 answer

How to set margins in a LinearLayout programmatically?

LinearLayout ll = new LinearLayout(this); ll.setOrientation(LinearLayout.VERTICAL); LinearLayout.LayoutParams layoutParams = ...READ MORE

answered Dec 20, 2018 in Java by Daisy
• 8,020 points
256 views
+5 votes
3 answers

How to execute a python file with few arguments in java?

You can use Java Runtime.exec() to run python script, ...READ MORE

answered Mar 27, 2018 in Java by DragonLord999
• 8,360 points

edited Nov 6, 2018 by Omkar 4,533 views
0 votes
1 answer

How can I convert a String variable to a primitive int in Java

You can convert a String to int by using a function: int ...READ MORE

answered Apr 12, 2018 in Java by sharth
• 3,310 points
45 views
0 votes
2 answers
0 votes
1 answer

How can we import javax.servlet API in Eclipse?

Before installing Eclipse, ensure that you are ...READ MORE

answered Jun 7, 2018 in Java by parth295
• 4,590 points
264 views
+28 votes
3 answers

How can we set java.library.path in Eclipse?

Go into the library settings for your ...READ MORE

answered Jul 3, 2018 in Java by sharth
• 3,310 points
1,104 views
0 votes
1 answer

Hadoop Documentation for Eclipse.

Few considerations to be taken are here: If ...READ MORE

answered Sep 11, 2018 in Big Data Hadoop by Frankie
• 9,570 points
31 views
0 votes
10 answers

How to import a jar file in Eclipse?

Go to your project right click and ...READ MORE

answered Dec 10, 2018 in Java by Hola77
19,304 views
0 votes
1 answer

How to set a timer in Java?

To work on timer in java, you ...READ MORE

answered May 16, 2018 in Java by Daisy
• 8,020 points
30 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.