Forum Stats

  • 3,740,363 Users
  • 2,248,239 Discussions
  • 7,861,216 Comments

Discussions

About Java Applet.

TechGeek!
TechGeek! Member Posts: 9
edited Oct 3, 2019 2:12PM in New To Java

Hi there!,

          I am new to java and was trying to execute a Java Applet program.... but unfortunately it ended up with some error.

The Applet window successfully shown off but it had something written "start:Applet not initialized".

I don't know what exactly the problem is.......

Can any one guide me in finding the right solution for this.

--------------------------------------------------------------------------------------------------------

Error: Applet not initialized

Java code:-

import java.awt.*;

import java.applet.*;

class Hello extends Applet

{

public void paint(Graphics g)

{

g.drawString("Hey! This is Java Applet...What's up??",100,100);

}

}

HTML code:-

<!doctype html>

<html>

<head></head>

<body>

<Applet code="Hello" height=500 width=500></Applet>

</body>

</html>

I ran the above codes and encountered "Applet not Initialized" Error..... What changes should I make in my code??

Regards,

TG.

Answers

Sign In or Register to comment.