Solving Ubuntu 12.04 Netbeans swing problem

I have tried to launch and run a new Swing application in Netbeans 7.0.1 but surprisingly, I saw that when I had run the application, Java gave me bunch of exceptions regarding that “package org.jdesktop.layout does not exist ubuntu”. At first I have thought that the problem might come from Open JDK but with further research I have found the solution¬† which seems that a small bug in NetBeans. It is very quick and easy fix, you just need follow the below steps,

1. Install libbatik-java package with apt-get

$ sudo apt-get install libbatik-java

2. Run Netbean in terminal with following command,

$ netbeans -cp:a /usr/share/java/batik-ext.jar

That is it, the problem solved and I finally I can run my Swing application without any issue on Ubuntu 12.04.

Send your idea and information to kasra@madadipouya.com

Leave a Reply