I am trying to convert a Java Applet to a Java Application. In the Applet there is the following...
Code:
  '
  '
Image offscreenImg;
  '
  '
offscreenImg = createImage(124, 180);
  '
  '
Now this works perfectly and the Applet runs the way it should.

In the Java Application I am doing this....
Code:
  '
  '
Image offscreenImg;
  '
  '
offscreenImg = Toolkit.getDefaultToolkit().createImage(124, 180);
  '
  '
I use the Toolkit.getDefaultToolkit() because I think this is what I have to do but when I compile the Application I get the following error:

error J0078: Class 'Toolkit' doesn't have a method that matches 'createImage(int, int)'

So, I looked up createImage on the Net and the information there said that createImage is a method of Toolkit. When I scaned all the methods I only found the following:

createImage(byte[] imagedata)
createImage(String filename)
createImage(URL url)
createImage(byte[] imagedata, int imageoffset, int imagelength)
createImage(ImageProducer producer)

So I see there is no method createImage(int, int).

So, my question is why does it compile and run OK in the Applet but it won't compile in the Application? Why does the Applet have createImage(int, int) but it does not exist in the Toolkit for the Application?

Here is the link for the information:

http://java.sun.com/j2se/1.4.2/docs/...t/Toolkit.html