Hi!
Im having problems with my java servlet. Im trying to generate a dynamic line chart.. the servlet code:
JFreeChart chart = createChart(dataset);
int width = 400;
int height = 300;
BufferedImage img = draw( chart, width, height );
OutputStream o = response.getOutputStream();
JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(o);
JPEGEncodeParam param = encoder.getDefaultJPEGEncodeParam(img);
param.setQuality(1.0f,true);
encoder.encode(img,param);
o.close();
When I try to open the servlet in my browser I get this error:
"HTTP 404 - File not found"
When I try to do the same thing with a "normal" image, the code above works..
I tried to write the CategoryDataSource getsSeriesCount() in this image but then the same error occured...
I'd be gratefull for any help here!!
generate dynamic linechart
RE: generate dynamic linechart
That seems pretty strange - I can't think of a reason why an image created using the JFreeChart draw() method should be any different to a regular image...anyone else?
DG.
DG.