Assigning appletContext to an applet
Posted on 1998-11-25
I have been working on making an applet that runs other applets. Everything works with most applets, but an applet which uses the getGraphics() method returns a null pointer exception. I believe, as someone suggested, I just need to assign the parent appletContext to the instance of the applet, but for some reason I have not been able to get that to work. This is essentially the part of the code I use to instantiate and run an applet:
the_frame = new Frame();
Exactly how can I can assign appletContext to this, and do I need to do any extra implements, import, or extends commands for my class? Will this allow me to use getGraphics() with the applets it runs?
Thanks a lot.