Using KarelJRobot in NetBeans

Create a new project. If the 'starting point' file is, after you create the project, NetBeans will look something like this:


What you should do to enable your project to access KarelJRobot.jar is right-click on the Libraries folder in the project. Choose Add JAR/Folder... That will look like:


Browse to KarelJRobot.jar and add it to your project. After you've done this, NetBeans should look like this:


Notice that KarelJRobot.jar is now in the Libraries folder, and all the red in has disappeared because the project now has access to KarelJRobot.jar.