This is my first post so please don't bite my head off!
I have found this: Java - How to import external packages?
and this: how to include libraries in java without using an IDE
but I'm still lost!
I have downloaded the file swingx-1.6.zip to my ~/Downloads folder (ubuntu) then unzipped it so I now have ~/Downloads/swingx-1.6 In this folder is swingx-1.6.jar which appears to have the class I want (JXPanel)
Then I ran this in a terminal:
javac -classpath :~/Downloads/swingx-1.6/swingx-1.6.jar Panels.java
were Panels.java is the class file which is (or will soon be) dependent on JXPanel.
I'm getting compile errors though!
Panels.java:6: package org.jdesktop.swingx does not exist
import org.jdesktop.swingx.JXPanel;
^
1 error
My question is: Have I included the right files in the -classpath
command? and Have I used the right import
command?...
sorry for being such a noob, I really don't want to migrate to an IDE. I was just getting the hang of where I am now lol thanks in advance for your help.