方法多着呢:
1:可以用水晶报表.
2:自己动手,在jsp页面放一个image,动态的改变她的heigh属性就可以了

解决方案 »

  1.   

    www.wave12.com
    这里有啊 功能很强大自己看看吧
      

  2.   

    jfreechart比较方便,柱状图,饼状图,趋势图都能作
      

  3.   

    水晶报表买不起, 其它报表工具都要付费的。因此, 建议你用applet, 在Jbuilder下可以托拉控件实现
      

  4.   

    如果仅仅要楼主说的功能,那么TABLE就可以搞定:<table><tr height='200'>
    <td width='20' valign='bottom'><table width='100%' bgcolor='RED'><tr><td height='80'>&nbsp;</td></tr></table>
    </td>
    <td width='20' valign='bottom'><table width='100%' bgcolor='RED'><tr><td height='150'>&nbsp;</td></tr></table>
    </td>
    <td width='20' valign='bottom'><table width='100%' bgcolor='RED'><tr><td height='120'>&nbsp;</td></tr></table>
    </td>
    </tr></table>
      

  5.   

    to:otom3(潇雨寒)到是一个办法,可我要从采集器得到数据,放到数据库里然后从数据库里得到数据,在页面实时自动更新
      

  6.   

    回楼上只要把表格高度用你数据库里的数据替换就可以了啊当然,数据要经过换算,变成0-800的数字动态改变可以设置成自动刷新
    也可以用iframe 中的JS改变每个状态条表格(需要给表格设置ID号)的height 属性
      

  7.   

    我用SVG,通过使用Servlet来封装SVG.....
      

  8.   

    严重同意  otom3(潇雨寒) ( ) 
    其实我也是这个意思,其实找一个矩形的picture,根据数据库中的值,实时的改变height的值,然后刷新,效果是一样的
      

  9.   


      第一步:创建一个Java Bean用来生成jpg文件   源程序如下: //生成图片的 Java Bean 
    //日期:2001-08-24 
    import java.io.*; 
    import java.util.*; 
    import com.sun.image.codec.jpeg.*; 
    import java.awt.image.*; 
    import java.awt.*; public class ChartGraphics { 
     BufferedImage image; 
     public void createImage(String fileLocation) { 
      try { 
       FileOutputStream fos = new FileOutputStream(fileLocation); 
       BufferedOutputStream bos = new BufferedOutputStream(fos); 
       JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(bos); 
       encoder.encode(image); 
       bos.close(); 
      } catch(Exception e) { 
       System.out.println(e); 
      } 
     }  public void graphicsGeneration(int h1,int h2,int h3,int h4,int h5) {   final int X=10; 
      int imageWidth = 300;//图片的宽度 
      int imageHeight = 300;//图片的高度 
      int columnWidth=30;//柱的宽度 
      int columnHeight=200;//柱的最大高度   ChartGraphics chartGraphics = new ChartGraphics(); 
      chartGraphics.image = new BufferedImage(imageWidth, imageHeight, BufferedImage.TYPE_INT_RGB); 
      Graphics graphics = chartGraphics.image.getGraphics(); 
      graphics.setColor(Color.white); 
      graphics.fillRect(0,0,imageWidth,imageHeight); 
      graphics.setColor(Color.red); 
      graphics.drawRect(X+1*columnWidth, columnHeight-h1, columnWidth, h1); 
      graphics.drawRect(X+2*columnWidth, columnHeight-h2, columnWidth, h2); 
      graphics.drawRect(X+3*columnWidth, columnHeight-h3, columnWidth, h3); 
      graphics.drawRect(X+4*columnWidth, columnHeight-h4, columnWidth, h4); 
      graphics.drawRect(X+5*columnWidth, columnHeight-h5, columnWidth, h5); 
      chartGraphics.createImage("D:\\temp\\chart.jpg"); 
     } 

       解释:createImage(String fileLocation)方法用于创建JPG图片,参数fileLocation为文件路径   graphicsGeneration(int h1,int h2,int h3,int h4,int h5)方法用于绘出图片的内容,参数h1……h5为每一个长方形的高度   第二步:创建另一个Java Bean从文本文件中读取数据(每一个长方形的高度),在实际应用中数据存储在Oracle数据库中   源程序如下: //读取Text文件中数据的 Java Bean 
    //作者:崔冠宇 
    //日期:2001-08-24 
    import java.io.*; 
    public class GetData { 
     int heightArray[] = new int[5]; 
     public int[] getHightArray() { 
      try { 
       RandomAccessFile randomAccessFile = new RandomAccessFile   ("d:\\temp\\ColumnHeightArray.txt","r"); 
       for (int i=0;i<5;i++) 
       { 
        heightArray[i] = Integer.parseInt(randomAccessFile.readLine()); 
       } 
      } 
      catch(Exception e) { 
       System.out.println(e); 
      } 
      return heightArray; 
     } 
    }    解释: getHightArray()用于从文本中读取数据,将文本中的String类型转换为int类型,并以数组类型返回。   第三步:创建JSP文件   源程序如下: 
    <%@ page import="ChartGraphics" %> 
    <%@ page import="GetData" %> 
    <jsp:useBean id="cg" class="ChartGraphics"/> 
    <jsp:useBean id="gd" class="GetData"/> 
    <%! 
    int height[]=new int[5]; 
    %> 
    <% 
    height=gd.getHightArray(); 
    cg.graphicsGeneration(height[0],height[1],height[2],height[3],height[4]); 
    %> 
    <html> 
    <body> 
    <img src="d:\temp\chart.jpg"></img> 
    </body> 
    </html>     解释:JSP首先调用Bean (GetData..class)读取文件中的数据,再调用Bean(ChartGraphics.class)生成图片,最后显示图片。 
      

  10.   

    to  kkgolf(浪漫之泪)好办法,不用去学别人的产品,不过兄台有这方面的资料吗,我要画好几种动态图,得自己掌握一套方法啊,请教