NetBeans

NetBeans is an IDE or Integrated Development Environment. It is FREE, open source, and has a worldwide community of users and developers.

It allows for quick and easy development of desktop, mobile and web applications with Java, JavaScript, HTML5, PHP, C/C++ and more.

Installation

First of all we need to install the latest version of the Java Development Kit (JDK). Once finished, we can download and setup NetBeans.

Downloading the Java Development Kit

First we need the latest version of the Java Development Kit (JDK).

Navigate to https://www.oracle.com and select Downloads.

Downloads Oracle
Image 1.13.1 - Downloads Oracle

Scroll down to the Java section and select Java (JDK) for Developers.

JDK Download
Image 1.13.2 - JDK Download

Now select Download below the Java symbol to download the latest stable version of the JDK (currently 10.0.2).

Download
Image 1.13.3 - Download

Last you need to accept the license agreement and download the Windows binary.

License and Windows binary
Image 1.13.4 - License and Windows binary

JDK Installation Wizard

Once fully downloaded you can start the installation wizard. Click Next to continue.

The Installation Wizard
Image 1.13.5 - The Installation Wizard

Keep the default selected features and click Next.

Default Features to Install
Image 1.13.6 - Default Features to Install

Be sure to make a note of where the JDK is being installed. We need it later on.

Clicking Next will open the JRE (Java Runtime Environment) install wizard.

Leave the Java path as is and click Next.

Keep the default path
Image 1.13.7 - Keep the default path

The installation should end successfully.

Keep the default path
Image 1.13.8 - Keep the default path

Click Close to finish the installation.

Downloading NetBeans

Currently the latest version of NetBeans is not available as an installer. It can only be downloaded as an extractable zip file. This is because NetBeans is trying to join the Apache Software Foundation (ASF) and is currently undergoing incubation.

To fetch the binaries, navigate to http://netbeans.apache.org/ and select Download.

Downloads
Image 1.13.9 - Downloads

Navigate to the "Downloads" section and click the link for Binaries.

Binaries
Image 1.13.10 - Binaries

Select the default mirror to download the zip-file from. If your download does not start, try another mirror.

Select download mirror
Image 1.13.11 - Select download mirror

Extracting NetBeans

Once the download is finished, extract the zip-file where you downloaded it. You should get a directory or subdirectory called netbeans. Move it to your c-drive, C:\Program Files or somewhere else where you install your applications.

Once moved, create a shortcut (drag netbeans64.exe and hold ALT or right click and select Create shortcut) from netbeans/bin/netbeans64.exe to your desktop or start-menu. Right click the shortcut and select Properties.

Select the Shortcut tab and add the java JDK path behind the name of the target as shown below:

"C:\Program Files\netbeans\bin\netbeans64.exe" --jdkhome "C:\Program Files\Java\jdk-10.0.2"
Shortcut Properties
Image 1.13.12 - Shortcut Properties

Once added, hit Apply and OK to save the shortcut.

Test installation

To test if your installation was successful launch the NetBeans IDE via the created shortcut. First time launching you should get the license agreement screen. Accept it.

License Agreement
Image 1.13.13 - License Agreement

Let us create a simple "Hello World" application in Java. Start by navigating to File => New Project. Make sure you selected Java - Java Application. Click Next.

Creating a new Java Application
Image 1.13.14 - Creating a new Java Application

Give your application a decent name such as "HelloWorldInJava". For the moment you can leave the default project location as is and click Finish.

Project Name
Image 1.13.15 - Project Name

Now you should see a code window with some readily generated Java code.

Blank Project
Image 1.13.16 - Blank Project

This however does not do anything. To make the program say hello to the world you should change the code between the curly braces {} as shown below.

public class HelloWorldInJava {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // Say hello world in Java
        System.out.println("Hello World!");
    }

}
Hello World in Java Code
Image 1.13.17 - Hello World in Java Code

Next hit the big green play button in NetBeans or press F6 on your keyboard to run the program. You should see the message at the bottom of the screen in the terminal window.

Well you are of to conquer the world with your program skills. Happy hacking.

results matching ""

    No results matching ""