Nothing Special   »   [go: up one dir, main page]

Setting Up Java and Eclipse Windows

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Setting Up Java and Eclipse for Windows

If you have any issues after completing this setup, please visit our page Support: Troubleshooting Common
Issues which provides solutions to many of the errors that our learners encounter.
In this course we (and you) will be using the Eclipse integrated development environment (IDE) to develop and
run our Java code. Eclipse is a powerful, industry-grade IDE. While it might be a little confusing at first
because of its power, once you get the hang of it, it will provide for a very pleasant programming experience
and youll wonder how you ever programmed without it!

Part 1: Install the Java JDK, if you dont have it already installed
Eclipse comes with its own compiler, which means many people are able to write programs using Eclipse
without installing the Java Development Kit (JDK for short). But having a working JDK is a very useful thing,
and is an easy way to prevent potential issues later on. Because of this, we recommend installing the JDK to
your system. In this class we have tested our files with Java versions 7 and 8, so if you have anything older
than that, youll want to upgrade.
1. Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html
2. Click on one of the buttons to download the latest version of the Java SE JDK. These buttons are
highlighted in the screenshot below (click either one).

3. Accept the license agreement in the first list of files titled Java SE Development Kit and then download
the file that is right for your operating system.

4. Install the JDK as appropriate for your operating system. If you need instructions, you can find them here:
Windows: http://docs.oracle.com/javase/7/docs/webnotes/install/windows/jdk-installation-windows.html
Linux: https://docs.oracle.com/javase/8/docs/technotes/guides/install/linux_jdk.html
Thats it. Youve got the Java SDK on your machine (SDK stands for software development kit -- a more
general term).

Part 2: Download, install and setup Eclipse


Next, you will install and setup eclipse. You might find the following guide helpful:
https://wiki.eclipse.org/Eclipse/Installation - Download_Eclipse And/or you can follow our instructions here:
1. Go to https://www.eclipse.org/downloads/
2. Select your operating system from the dropdown menu in the upper right. Then, in the row titled Eclipse
IDE for Java Developers, click on 32 or 64-bit as appropriate to go to the download page.

3. Click the Download button to start your download. Save the compressed (.zip) file wherever you want on
your computer.
4. Uncompress the downloaded file to any location on your computer. Note: Eclipse will run from here. There
is nothing else you need to do to install it. However, Windows users should note the following warning from
https://wiki.eclipse.org/Eclipse/Installation#Download_Eclipse
Note that there is a known problem with the built-in decompression utility on all current versions of
Windows. We recommend that you use a more robust decompression utility such as the open source 7zip
when decompressing an Eclipse download. Some people report success when initially decompressing
Eclipse into a root directory (e.g. c:\) and then moving it to a more appropriate home (e.g. c:\Program
Files\Eclipse)
5. Once Eclipse is unzipped, run it by either double-clicking on eclipse.exe (Windows and Mac) or typing
eclipse at the command line (Linux--make sure it is on your path).

6. Eclipse will ask you to select your workspace. This is where eclipse will store all of your code and project
files. We recommend you choose a directory that gets backed up regularly (e.g. on Google Drive, for
example). Optionally, make this the default workspace (so Eclipse will not ask you every time).

7. Then you will see a welcome screen that has links to a bunch of information including tutorials and
overviews. We encourage you to try out some of these, but if you just want to dive in and get started, click the
Workbench icon in the top right corner.

Setting Up the Correct JDK


IMPORTANT: Sometimes Eclipse will not use the version of Java that we have installed. This can create
problems later on. Follow these steps to make sure Eclipse is using the version of Java that we installed in
Part 1.
1. Go to Window->Preferences.

2. In the window that opens select Java->Installed JREs in the menu on the left. In the main portion of the
window will be listed each version of Java that Eclipse knows about. If you see the newer version of Java that
you installed, then make sure the box next to it is checked and click OK. If you do not see the newer version
of Java you installed, then click Search

3. Navigate to where you installed the JDK in Part 1. Make sure you select the JDK directory and not the
newly installed JRE directory! Then click OK.

4. After a moment, eclipse should list a second JRE in the Java->Installed JREs window. Select the JRE in the
newly installed JDK folder, and click OK:

You are now ready to setup and start working with UnfoldingMaps!

You might also like