http://www-900.ibm.com/developerWorks/cn/java/l-jfreechart/index.shtml?ca=dwcn-isc&me=ccid
这里。。

解决方案 »

  1.   

    首先感谢上面的哥们,你是第一个对我问题感兴趣的人,一定给你分.但是他遇到的错误和我遇到的错误不一样.另外:
    在运行这些代码时给虚拟机指定参数-Dsun.java2d.noddraw即可。
    如何指定?我对这些配置不大了解..请指教..谢谢.
      

  2.   

    在运行这些代码时给虚拟机指定参数-Dsun.java2d.noddraw即可。运行程序的时候 java -Dsun.java2d.noddraw ...
      

  3.   

    在linux中设置
    #DISPLAY=localhost:0.0; export DISPLAY
      

  4.   

    在linux中设置
    #DISPLAY=localhost:0.0; export DISPLAY
    这个方法我试验了..不好用
      

  5.   

    在运行这些代码时给虚拟机指定参数-Dsun.java2d.noddraw即可。运行程序的时候 java -Dsun.java2d.noddraw ...
    这个方法我不知道怎么做,能不能说具体点?
      

  6.   

    Jfreechart用了JAVA的图形包,你启动TOMCAT需要在LINUX图形界面启动之后才可以,我以前就遇到过,试了N次之后才找到原因
      

  7.   

    我记得JFreeChart里是说过这个问题
    好像在Windows下调用了部分微软专有的函数,即dll文件
    去到Linux显示就有问题,解决的办法是,加载这些微软的函数
    至于是什么函数,我就忘记了自己查一下(^_^)
      

  8.   

    需要启动linux的图形界面,你可以直接登陆linux的图形截面,启动tomcat。
    出现这种问题,还会有一种情况,就是你在远程启动服务器的时候,因为没有启动图形功能,也会出现这种问题,解决的方法就是在服务器上加入你启动服务器的客户机的ip即可!
      

  9.   

    This is most likely because the server doesn't have a graphical subsystem (i.e. a graphics card and monitor). The Flex server uses Java's AWT (Abstract Window Toolkit) to implement compile time image embedding and SVG. By default, the Java Virtual Machine tries to use the hardware-based graphical capabilities of the machine to implement AWT. For servers without a graphical interface, the above error will be thrown.To resolve this issue, set the system property java.awt.headless to true so that the JVM will implement AWT in software, rather than attempting to use non-existent hardware-based graphics.Note: java.awt.headless is only available with JDK 1.4 and above. It is not available on previous versions of the JDK.There are one ways to set java.awt.headless to true:    * Using the command line:      -Djava.awt.headless=true 
    http://forum.java.sun.com/thread.jsp?thread=280804&forum=57&message=2472321