I'm really disappointed about that when I use Swing Java in "IntelliJ" it runs without any problem but when I use JGoodies… FormLayout it doesn't run with me and show error that:
Exception in thread "main" java.lang.NoClassDefFoundError: com/jgoodies/forms/layout/FormLayout
This is the code:
import javax.swing.*;
import java.awt.*;
public class Adddata extends JFrame {
private JPanel mainpanlll;
public Adddata(String title ) {
super(title);
try {
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setContentPane(mainpanlll);;
this.pack();
} catch (Exception e )
{
e.getMessage();
}
}
public static void main(String[] args) {
try {
JFrame frame = new Adddata("HI");
frame.setVisible(true);
} catch (Exception e )
{
e.getMessage();
}
}
}
and this is the error massage hereenter image description here
Ok finaly after 2 days searching it show that I must download jgoodies-common-x.x.x.jar and jgoodies-forms-x.x.x.jar and add it to libary