I'm working on a Swing application that has to be localized.
For that purpose, I'm using a resourceBundle
. It works fine when I run the application from the IDE. But when I use maven
to generate the jar, the application starts up normally but the internationalization stops working. Without throwing any exception, I have make a lot of variations to solve that problem; I even have make a class that inherits from java.util.ResourceBundle.Control
. The only thing I've achieved to make it work is by placing the properties files outside the package (I place it into the desktop just for testing). I then try to use the same method by specifying the path by new File(".").getAbsolutePath()
.
Doing that still keeps working from running it from Eclipse, but when I try to generate the jar and execute it, it throws an exception and the application does not start.