Archived

This topic is now archived and is closed to further replies.

[java] java applet on microsoft internet explorer?

This topic is 5515 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

i have a really wierd problem. I cannot get applets to work in an internet explorer. the applet shows up but it is a blank grey rectangle. here is my code.... import java.applet.*; import java.awt.*; /* * file name is world.java for source world.class for compiled * file. * * The HelloWorld class implements an applet that * simply displays "Hello World!". */ public class world extends Applet { public void paint(Graphics g) { g.drawString("Hello world!", 50, 25); // Display "Hello world!" } } and my html file looks like this(i only put endmarkers(>) so that it would show here) HTML> HEAD> TITLE>The Hello World Applett TITLE BODY> APPLET height=480 width=640 code="./world.class"> /APPLET> /BODY> /HTML> [edited by - phillk6751 on November 8, 2002 4:14:31 PM]

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
It sounds like you may be compiling with J2SDK 1.4 but trying to run on JRE 1.1, which requires that you use the -target 1.1 command line option when you compile (ie "javac -target 1.1 HelloWorldApplet.java" etc.)

Installing the J2SDK or Java Plugin on this computer will also solve the problem

Share this post


Link to post
Share on other sites