[3189] in java-interest
Re: HelloWorldApplet does not work.
daemon@ATHENA.MIT.EDU (Kathy Walrath)
Thu Nov 2 19:50:13 1995
Date: Thu, 2 Nov 1995 13:41:09 -0800
From: kwalrath@scndprsn.eng.sun.com (Kathy Walrath)
To: jeremyc@prgone.com
Cc: java-interest@java.Eng.Sun.COM
Hi, Jeremy--
You've got a weird mix of a beta applet and alpha HTML. If you
look at http://java.sun.com/progGuide/getStarted/applet/index.html,
you'll see the instructions for making a beta applet and including
it in a page with the APPLET tag (you used the APP tag, which only
works for alpha).
Netscape 2.0 and the JDK appletviewer should be able to view this
applet, but HotJava won't be able to, since it understands only
alpha applets.
--Kathy
------------Begin included message------------
From: Jeremy Cowgar <jeremyc@prgone.com>
Date: Wed, 1 Nov 1995 21:23:27 -0500
Subject: HelloWorldApplet does not work.
I cannot get the HelloWorldApplet to work in Netscape 2.0b1j, or HotJava =
for Windows95. Here is the applet source code that I have entered.
import java.applet.*;
import java.awt.*;
class HelloWorldApplet extends Applet {
public void init() {
resize(150,25);
}
public void paint(Graphics g) {
g.drawString("Hello World", 50, 25);
}
}
My HTML code is the following:
<HTML>
<HEAD><TITLE>Java Enhanced</TITLE></HEAD>
<BODY>
<APP CLASS=3D"HelloWorldApplet" WIDTH=3D100 HEIGHT=3D100>
<HR NOSHADE>
<A HREF=3D"classes/HelloWorldApplet.java">The Source</A>
</BODY>
</HTML>
The HelloWorldApplet compiled with no errors, and the =
HelloWorldApplet.class file is located in ./classes/ ... I have tried =
moving it to the same directory as example1.html, but nothing produces a =
HTML page with the text, Hello World, on it.
Please Help,
Jeremy Cowgar
-----------End included message------------
-
This message was sent to the java-interest mailing list
Info: send 'help' to java-interest-request@java.sun.com