V
vizlab
Hi:
On windows XP, I have a servlet in which ToolkitImage calls
getGraphics().
The error below always occurs:
java.lang.UnsupportedOperationException: getGraphics() not valid for
images created with createImage(producer)
sun.awt.image.ToolkitImage.getGraphics(Unknown Source)
Basically, I use BufferedImage to generate a image and then save it.
But when I generate the image, for some reason,
ToolkitImage.getGraphics() is used. This triggered exceptions.
I have already set -Djava.awt.headless=true.
When I run the servlet on linux, it works fine.
When I run the servlet in eclipse on Window XP, the error occurs.
Can anybody tell the reason?
Thanks a lot for your help.
Best
Lian
On windows XP, I have a servlet in which ToolkitImage calls
getGraphics().
The error below always occurs:
java.lang.UnsupportedOperationException: getGraphics() not valid for
images created with createImage(producer)
sun.awt.image.ToolkitImage.getGraphics(Unknown Source)
Basically, I use BufferedImage to generate a image and then save it.
But when I generate the image, for some reason,
ToolkitImage.getGraphics() is used. This triggered exceptions.
I have already set -Djava.awt.headless=true.
When I run the servlet on linux, it works fine.
When I run the servlet in eclipse on Window XP, the error occurs.
Can anybody tell the reason?
Thanks a lot for your help.
Best
Lian