I want to generate bar graph using JFreeChart in Java on Ubuntu. When I am running my program in local through eclipse, it is working fine and opening a new window with bar graph. When I deploy the code in Ubuntu and execute the same jar file, it is not opening a window. I am getting this:
Exception in thread "main" java.awt.AWTError: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable. at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method) at sun.awt.X11GraphicsEnvironment.access$200(X11GraphicsEnvironment.java:65)