How do I create a Hello World Applet?
Category: java.applet, viewed: 10K time(s).
The code below demonstrate the very basic of Java applet. Applet is a small Java application that can be embedded on the web browser.
To display the applet we need to create an HTML document. Here is a simple example of the document.
<html>
<head>
<title>Hello World Applet</title>
</head>
<body>
<applet
code="org.kodejava.example.applet.HelloWorldApplet"
height="250"
width="250">
</applet>
</body>
</html>
You can now load the applet in your browser or by using the appletviewer utility.
More examples on java.applet
|
|